Navigation: Scripting > System Scripts > System Script Date/Time Functions |
|
vbld_FormatDate(): returns the current date in the form YYYYMMDD.
vbld_FormatDateD(dte): returns the given date in the form YYYYMMDD.
vbld_FormatDateEx(dateStr, format): parses and formats the given date+time as specified.
Available format strings:
yyyy |
4-digit year |
yy |
2-digit year (left padded with 0s) |
y |
1- or 2-digit year |
mmmm |
Month name |
mmm |
Month name (abbreviated) |
mm |
Month (left padded with 0s) |
m |
Month |
dd |
Day (left padded with 0s) |
d |
Day |
hh |
24-hr hour (left padded with 0s) |
h |
24-hr hour |
HH |
12-hr hour (left padded with 0s) |
H |
12-hr hour |
MM |
Minutes (left padded with 0s) |
M |
Minutes |
SS |
Seconds (left padded with 0s) |
S |
Seconds |
AP |
AM/PM |
A |
A/P |
ap |
am/pm |
a |
a/p |
vbld_FormatDateTime(): returns the current date+time in the locale-neutral form DYYYYMMDDTHHMMSS, useful for storing a timestamp in a macro.
vbld_FormatDateTimeD(dte): returns the given date+time the locale-neutral form DYYYYMMDDTHHMMSS.
vbld_FormatTime(): returns the current time in the form HHMMSS.
vbld_FormatTimeT(dte): returns the given time in the form HHMMSS.
vbld_ParseFormattedDateTime(dateStr): returns a string formatted with vbld_FormatDateTime as a date variable, useful for retrieving from a macro.