Export (0) Print
Expand All
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Calendar and DTP Controls

Windows Mobile 6.5

This code sample is named CalendarAndDTP. It demonstrates how to use the Calendar Controls and the Date and Time Picker (DTP) Controls, the use of custom formats in the DTP control, and Calendar Control styles.

  1. Navigate to the solution file (*.sln), and double-click it. By default, the solution file is copied to the following folder:

    C:\Program Files\Windows Mobile 6.5.3 DTK\Samples\PocketPC\CPP\win32\CalendarAndDTP

    Microsoft Visual Studio launches and loads the solution.

  2. Build the solution (Ctrl+Shift+B).

  3. Deploy the solution (F5).

SDK: Windows Mobile Professional SDK and Windows Mobile Standard SDK

Development Environment: Visual Studio 2005 or 2008.

ActiveSync: Version 4.5.

ExTAPIAsync demonstrates how to develop an application that is based on Extended TAPI asynchronous functionality.

The following code is needed to use the calendar and DTP controls.

icex.dwSize = sizeof(icex);

icex.dwICC = ICC_DATE_CLASSES;You can create the second screen with scrollbars, and then pan a full year.

The controls are physically laid out on dialog boxes to make them easier to position and interact with at design time. In the dialog editor, they are the grey boxes on the dialog boxes. To set specific styles for these controls, open the *.RC file as a text file, find the control you want, and add or delete the style. For example, in the *.RC file, there will be a line that looks like this:

CONTROL "",IDC_CONTROL_DTS_LONGDATEFORMAT,"SysDateTimePick32", 0x4,0,0,124,12

Add a new style next to the "0x4", such as "0x4 | DTM_STYLE". It will be changed by the dialog compiler to the correct hex value, provided the <commctrl.h> file is included. It is included in the resource.h file in this example.

Community Additions

© 2014 Microsoft