XFA Specification
Chapter 23, FormCalc Specification
Date And Time Built-in Functions
845
IsoDate2Num()
This function returns the number of days since the
epoch,
given an
[ISO-8601]
date string.
Syntax
IsoDate2Num(d1)
Parameters
d1
is a canonical date string in one of the following two formats:
YYYY[MM[DD]]
YYYY[-MM[-DD]]
or, is an ISO-8601 date-time string — the concatenation of an ISO-8601 date string with an
ISO-8601 time string, separated by the character T, as in:
1997-07-16T20:20:20
Returns
The days from the
epoch
or null if its parameter is null.
If the given date is not in one of the accepted formats, the function returns 0.
Examples
Calling IsoDate2Num() as follows
IsoDate2Num("1900")
IsoDate2Num("1900-01")
IsoDate2Num("1900-01-01")
IsoDate2Num("19960315T20:20:20")
IsoDate2Num("2000-03-01") - IsoDate2Num("20000201")
Returns
1
1
1
35138
29
See Also
IsoTime2Num()
and
Num2Date()
Home Index Bookmark Pages
Pages: Home Index All Pages