Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

This macro retrieves date information (using SYSTEMTIMEstructures) that represents the high and low limits of a month calendar control's display.

Syntax

DWORD MonthCal_GetMonthRange(
  HWND 
hwndMC, 
  DWORD 
dwFlag, 
  LPSYSTEMTIME 
lprgSysTimeArray 
);

Parameters

hwndMC

Handle to a month calendar control.

dwFlag

Specifies the scope of the range limits to be retrieved. It is one of the following values.

Value Description

GMR_DAYSTATE

Include preceding and trailing months of visible range that are only partially displayed.

GMR_VISIBLE

Include only those months that are entirely displayed.

lprgSysTimeArray

Long pointer to a two-element array of SYSTEMTIMEstructures that will receive the lower and upper limits of the scope specified by dwFlag. The lower and upper limits are placed in lprgSysTimeArray[0] and lprgSysTimeArray[1], respectively. The time members of these structure are not modified.

Return Value

Returns an INTthat represents the range, in months, spanned by the two limits returned at lprgSysTimeArray.

Remarks

Related message:  MCM_GETMONTHRANGE

Requirements

Header commctrl.h
Windows Embedded CE Windows CE 2.0 and later
Windows Mobile Windows Mobile Version 5.0 and later

See Also

Other Resources

SYSTEMTIME