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

All Windows Mobile functions and external interfaces represent a year with four digits, for example 2020. The OEM is responsible for storing a compressed date in the OEM adaptation layer (OAL) so that it passes the correct date to the hardware. This compressed date can have up to a 100-year range, for example 1950 to 2049.

Windows Mobile does not have any inherit logic for converting two-digit years to four-digit years. OLE functions convert all two-digit years ending in 29 or less to twenty-first century dates. They convert all two-digit years ending in 30 or more to twentieth century dates. For example, OLE converts 29 to 2029 and 30 to 1930. OLE internal functions use four-digit years. They only convert two-digit years to four-digit years when an application supplies a two-digit year string to an OLE function. OLE conversions do not affect the date information used by the OS.

You can use the real-time clock functions to make sure that your OS design handles dates properly. Use the GetSystemTime, the SetSystemTime, and the CeSetUserNotificationfunctions to set, and then retrieve, various twentieth-century and twenty-first century dates.

See Also