| Function group | Execute on client | Platform(s) |
| Date and time | YES | All |
dat(datestring|number[,dateformat])
Converts a datestring or number to a date value using an optional dateformat string and returns the result. JavaScript client-executed methods do not support number.
If you do not specify a dateformat, the first argument is converted using #FD. You can use the following symbols in the dateformat string:
| Y | Year (03) | d | Day (12th) |
|
y |
Year (2003) |
W |
Day of week (5) |
|
C |
Century (20) |
w |
Day of week (Friday) |
|
M |
Month (06) |
V |
Short day of week (Fri) |
|
m |
Month (JUN) |
E |
Day of year (1-366) |
|
n |
Month (June) |
G |
Week of year (1-52) |
|
D |
Day (12) |
F |
Week of month (1-6) |
CalculatelDateasdat('May 8th, 03')# returns '8 MAY 03' if #FD = 'D m Y'
CalculatelDateasdat('May 8th, 2003','MDY')# returns 050803
CalculatelDateasdat(91,'w, d n, y')# returns 'Monday, 1st April, 1901' i.e. the 91st day of 1901