CDateTimeCtrl

A CDateTimeCtrl object encapsulates the functionality of a date and time picker control. The date and time picker control (DTP control) provides a simple interface to exchange date and time information with a user. This interface contains fields, each of which displays a part of the date and time information stored in the control. The user can change the information stored in the control by changing the content of the string in a given field. The user can move from field to field using the mouse or the keyboard.

You can customize the date and time picker control by applying a variety of styles to the object when you create it. See Date and Time Picker Control Styles in the Platform SDK for more information about styles specific to the date and time picker control. You can set the display format of the DTP control using format styles. These format styles are described in Preset DTP Display Formats in the Platform SDK.

The date and time picker control also uses notifications and callbacks, which are described in Using CDateTimeCtrl in the Visual C++ Programmer’s Guide.

#include <afxdtctl.h>

Class MembersBase ClassHierarchy Chart

Samples   MFC Sample CMNCTRL1

See Also   CMonthCalCtrl