CDateTimeCtrl::SetTime

BOOL SetTime( const COleDateTime& timeNew );

BOOL SetTime( const CTime* pTimeNew );

BOOL SetTime( LPSYSTEMTIME pTimeNew = NULL );

Return Value

Nonzero if successful; otherwise 0.

Parameters

timeNew

A reference to a COleDateTime object containing the to which the control will be set.

pTimeNew

In the second version above, a pointer to a CTime object containing the time to which the control will be set. In the third version above, a pointer to a SYSTEMTIME structure containing the time to which the control will be set.

Remarks

This member function implements the behavior of the Win32 message DTM_SETSYSTEMTIME, as described in the Platform SDK.

In the MFC implementation of SetTime, you can use the COleDateTime or CTime classes, or you can use a SYSTEMTIME structure, to set the time information.

CDateTimeCtrl OverviewClass MembersHierarchy Chart

See Also   CDateTimeCtrl::GetTime