|
The following list applies to Web Component widgets that are available as part of the ThingWorx Web Component SDK.
|
Type
|
Format
|
Output
|
Example
|
---|---|---|---|
Weekdays
|
d
|
Displays a range between 0 and 6, where 0 is Sunday and 6 is Saturday.
|
1
|
dd
|
Displays the first two letters of the day.
|
Mo
|
|
ddd
|
Displays the first three letters of the day.
|
Mon
|
|
dddd
|
Displays the full name of the day of the week.
|
Monday
|
|
Years
|
YY
|
Displays the year as a two-digit number with a leading zero. For example, 2009 is displayed as 09.
|
09
|
YYYY
|
Displays the year as a four-digit number.
|
2009
|
|
Months
|
M
|
Displays the month number as a range between 1 and 12, where January is 1 and December is 12.
|
1
|
Mo
|
Displays the month number as a range between 1 and 12 with an ordinal indicator, where January is 1st and December is 12th.
|
12th
|
|
MM
|
Displays the month number as a range between 01 and 12, where January is 01 and December is 12.
|
01
|
|
MMM
|
Displays the month as an abbreviated string.
|
Jan
|
|
MMMM
|
Displays the full month name as a string: January
|
January
|
|
Quarters
|
Q
|
Displays the quarter number as a range between 1 and 4.
|
2
|
Qo
|
Displays the quarter number as number between 1 and 4 with an ordinal indicator.
|
2nd
|
|
Days
|
D
|
Displays the day of the month as a number range between 1 and 31.
|
30
|
Do
|
Displays the day of the month as a number range between 1 and 31 including an ordinal indicator, where the first day is 1st and last day is 31st.
|
30th
|
|
DD
|
Displays The day number between 01 and 31.
|
23
|
|
Day of the year
|
DDD
|
Displays the day of the year as a number range between 1 and 365.
|
51
|
DDDo
|
Displays the day of the year as a range between 1 and 365, including an ordinal indicator, where the first day is 1st and last day is 365th.
|
51st
|
|
DDDD
|
Displays the day of the year as a number range between 001 and 365.
|
051
|
|
Week of the year
|
w
|
Displays the current week from a range of numbers between 1 and 53.
|
42
|
wo
|
Displays the week number as a number range between 1 and 53, including an ordinal indicator.
|
42nd
|
|
ww
|
Displays the current week from a range of numbers between 1 and 53. A leading zero is displayed for numbers under 10.
|
01
|
Type
|
Format
|
Output
|
Example
|
---|---|---|---|
24–hour format
|
H
|
Displays hours in a 24–hour format.
|
• 0
• 23
|
HH
|
Displays hours in a 24–hour format, with a leading zero for values under 10.
|
• 00
• 23
|
|
12–hour format
|
h
|
Displays hours in a 12–hour format.
|
• 1
• 12
|
hh
|
Displays hours in a 12–hour format, with a leading zero for values under 10.
|
• 01
• 12
|
|
Minutes
|
m
|
Displays minutes.
|
• 0
• 59
|
mm
|
Displays minutes as two digits with a leading zero for values under 10.
|
• 00
• 59
|
|
Seconds
|
s
|
Displays seconds
|
• 0
• 59
|
ss
|
Displays seconds with a leading zero.
|
• 00
• 59
|
|
AM/PM
|
a
|
Displays a lowercase AM and PM abbreviations when using a 12–hour format.
|
• am
• pm
|
A
|
Displays uppercase AM and PM abbreviations when using a 12–hour format.
|
• AM
• PM
|
|
Millieseconds
|
SSS
|
Displays one thousandth of a second.
|
001
|
Centiseconds
|
SS
|
Displays one hundredth of a second.
|
01
|
Deciseconds
|
S
|
Displays one tenth of a second.
|
1
|
Timezone offset
|
Z
|
Displays the Coordinated Universal Time (UTC)offset for the current time zone.
|
+3:00
|
ZZ
|
The UTC offset for the current time zone without the colon separator.
|
+300
|