SECDateTimeCtrl::SetFormat
Sets the current date/time format.
Defined in: DTCtrl.cpp
Syntax
SetFormat(FormatType format);
SetFormat(LPCTSTR lpszFormat);
Return Value
void
Parameters
format
Format type.
lpszFormat
Format string.
Comments
Format types include:
SECDateTimeCtrl::Time
Locale time format
SECDateTimeCtrl::ShortDate
Locale short date format
SECDateTimeCtrl::LongDate
Locale long date format
SECDateTimeCtrl::Custom
A user supplied date/time format string
Format strings used by SECDateTimeCtrl::SetFormat are as follows:
h
Hours
hh
Hours with leading zero
H
Same as h, but 24-hour format
HH
Same as hh, but 24-hour format
m
Minutes
mm
Minutes with leading zero
s
Seconds
ss
Seconds with leading zero
t
Abbreviated AM/PM designator
tt
Full AM/PM designator
d
Numeric day
dd
Numeric day with leading zero
ddd
Abbreviated day name
dddd
Full day name
M
Month
MM
Month with leading zero
MMM
Abbreviated month
MMMM
Full month name
y
Year without century
yy
Year with leading zero, without century
yyyy
Year including century
gg
Era (ignored)
'text'
Quoted text passed straight through
See Also