Share via


CMFCToolBarDateTimeCtrl Class

A toolbar button that contains a date and time picker control (CMFCToolBarDateTimeCtrlImpl Class).

class CMFCToolBarDateTimeCtrl : public CMFCToolBarButton

Members

Public Constructors

Name

Description

CMFCToolBarDateTimeCtrl::CMFCToolBarDateTimeCtrl

Constructs a CMFCToolBarDateTimeCtrl object.

CMFCToolBarDateTimeCtrl::~CMFCToolBarDateTimeCtrl

Destructor.

Public Methods

Name

Description

CMFCToolBarDateTimeCtrl::CanBeStretched

Specifies whether a user can stretch the button during customization. (Overrides CMFCToolBarButton::CanBeStretched.)

CMFCToolBarDateTimeCtrl::CopyFrom

Copies the properties of another toolbar button to the current button. (Overrides CMFCToolBarButton::CopyFrom.)

CMFCToolBarDateTimeCtrl::DuplicateData

Reserved for future use.

CMFCToolBarButton::ExportToMenuButton

Copies text from the toolbar button to a menu.

CMFCToolBarDateTimeCtrl::CreateObject

Used by the framework to create a dynamic instance of this class type.

CMFCToolBarDateTimeCtrl::GetByCmd

Retrieves the first CMFCToolBarDateTimeCtrl object in the application that has the specified command ID.

CMFCToolBarDateTimeCtrl::GetDateTimeCtrl

Returns a pointer to the date and time picker control.

CMFCToolBarDateTimeCtrl::GetHwnd

Retrieves the window handle that is associated with the toolbar button. (Overrides CMFCToolBarButton::GetHwnd.)

CMFCToolBarDateTimeCtrl::GetThisClass

Used by the framework to obtain a pointer to the CRuntimeClass object that is associated with this class type.

CMFCToolBarDateTimeCtrl::GetTime

Gets the selected time from a date and time picker control and puts it in a specified SYSTEMTIME structure.

CMFCToolBarDateTimeCtrl::GetTimeAll

Returns the selected time from the time picker control button that has a specified command ID.

CMFCToolBarDateTimeCtrl::HaveHotBorder

Determines whether a border of the button is displayed when a user selects the button. (Overrides CMFCToolBarButton::HaveHotBorder.)

CMFCToolBarDateTimeCtrl::NotifyCommand

Specifies whether the button processes the WM_COMMAND message. (Overrides CMFCToolBarButton::NotifyCommand.)

CMFCToolBarDateTimeCtrl::OnAddToCustomizePage

Called by the framework when the button is added to a Customize dialog box. (Overrides CMFCToolBarButton::OnAddToCustomizePage.)

CMFCToolBarDateTimeCtrl::OnCalculateSize

Called by the framework to calculate the size of the button for the specified device context and docking state. (Overrides CMFCToolBarButton::OnCalculateSize.)

CMFCToolBarDateTimeCtrl::OnChangeParentWnd

Called by the framework when the button is inserted into a new toolbar. (Overrides CMFCToolBarButton::OnChangeParentWnd.)

CMFCToolBarDateTimeCtrl::OnClick

Called by the framework when the user clicks the control. (Overrides CMFCToolBarButton::OnClick.)

CMFCToolBarDateTimeCtrl::OnCtlColor

Called by the framework when the parent toolbar handles a WM_CTLCOLOR message. (Overrides CMFCToolBarButton::OnCtlColor.)

CMFCToolBarDateTimeCtrl::OnDraw

Called by the framework to draw the button by using the specified styles and options. (Overrides CMFCToolBarButton::OnDraw.)

CMFCToolBarDateTimeCtrl::OnDrawOnCustomizeList

Called by the framework to draw the button in the Commands pane of the Customize dialog box. (Overrides CMFCToolBarButton::OnDrawOnCustomizeList.)

CMFCToolBarDateTimeCtrl::OnGlobalFontsChanged

Called by the framework when the global font has changed. (Overrides CMFCToolBarButton::OnGlobalFontsChanged.)

CMFCToolBarDateTimeCtrl::OnMove

Called by the framework when the parent toolbar moves. (Overrides CMFCToolBarButton::OnMove.)

CMFCToolBarDateTimeCtrl::OnShow

Called by the framework when the button becomes visible or invisible. (Overrides CMFCToolBarButton::OnShow.)

CMFCToolBarDateTimeCtrl::OnSize

Called by the framework when the parent toolbar changes its size or position and this change causes the button to change size. (Overrides CMFCToolBarButton::OnSize.)

CMFCToolBarDateTimeCtrl::OnUpdateToolTip

Called by the framework when the parent toolbar updates its tooltip text. (Overrides CMFCToolBarButton::OnUpdateToolTip.)

CMFCToolBarDateTimeCtrl::Serialize

Reads this object from an archive or writes it to an archive, (Overrides CMFCToolBarButton::Serialize.)

CMFCToolBarDateTimeCtrl::SetStyle

Sets the style of the toolbar button. (Overrides CMFCToolBarButton::SetStyle.)

CMFCToolBarDateTimeCtrl::SetTime

Sets the time and date in the time picker control.

CMFCToolBarDateTimeCtrl::SetTimeAll

Sets the time and date in all instances of the time picker control that have a specified command ID.

Remarks

For an example of how to use a date and time picker control, see the ToolbarDateTimePicker sample project. For information about how to add control buttons to toolbars, see How to: Put Controls On Toolbars.

Inheritance Hierarchy

CObject

   CMFCToolBarButton

      CMFCToolBarDateTimeCtrl

Requirements

Header: afxtoolbardatetimectrl.h

See Also

Concepts

MFC Hierarchy Chart

How to: Put Controls On Toolbars

Reference

CMFCToolBarButton Class

CMFCToolBarDateTimeCtrlImpl Class

Other Resources

Classes (MFC Feature Pack)