Format
- Last UpdatedJan 25, 2024
- 2 minute read
The Format property is a read-write property that gets or sets the date and time formats for the control.
Syntax
aaHistClientTimeRangePicker.Format = message;
Result = aaHistClientTimeRangePicker.Format;
Remarks
To display the string literals that contain date and time separators or format strings, you must use escape characters in the substring. For example, to display the date and time as 06/15/2001 12:00 PM, this property must be set to:
"dd'/'MM'/'yyyy hh':'mm tt"
The following table lists all the valid format strings and their descriptions.
|
Format String |
Description |
|---|---|
|
d |
The one or two-digit day. |
|
dd |
The two-digit day. Single digit day values are preceded by a zero. |
|
ddd |
The three-character day-of-week abbreviation. |
|
dddd |
The full day-of-week name. |
|
h |
The one or two-digit hour in 12-hour format. |
|
hh |
The two-digit hour in 12-hour format. Single digit values are preceded by a zero. |
|
H |
The one or two-digit hour in 24-hour format. |
|
HH |
The two-digit hour in 24-hour format. Single digit values are preceded by a zero. |
|
m |
The one or two-digit minute. |
|
mm |
The two-digit minute. Single digit values are preceded by a zero. |
|
M |
The one or two-digit month number. |
|
MM |
The two-digit month number. Single digit values are preceded by a zero. |
|
MMM |
The three-character month abbreviation. |
|
MMMM |
The full month name. |
|
s |
The one or two-digit seconds. |
|
ss |
The two-digit seconds. Single digit values are preceded by a zero. |
|
t |
The one-letter AM/PM abbreviation ("AM" appears as "A"). |
|
tt |
The two-letter AM/PM abbreviation ("AM" appears as "AM"). |
|
y |
The one-digit year (2001 appears as "1"). |
|
yy |
The last two digits of the year (2001 appears as "01"). |
|
yyyy |
The full year (2001 appears as "2001"). |
Remarks
The default format is M/d/yyyy h:mm:ss tt for English systems.