getCurrentTime
Returns a datetime object for the current date and time.
The default timezone is GMT, but you can select another by using the optional parameter. All supported timezones are included in the parameter dropdown in the Function Builder.
Alternatively, you can specify a fixed offset from GMT.
Parameters
TIME ZONE (string)
Optional. A string representing a regional timezone (e.g. Europe/Berlin). Alternatively, give a fixed offset in hours (e.g. +02:00).
Default: GMT
Examples
Assume each call occurred on Dec 2, 2021 at 11:35:24 AM (GMT).
ATL in Script | Result |
---|---|
| Dec 2, 2021 11:35:24 AM |
| Dec 2, 2021 1:25:24 PM |
| Dec 2, 2021 6:35:24 AM |
| Dec 2, 2021 10:35:24 AM |
| Dec 2, 2021 12:35:24 PM |
| Dec 2, 2021 10:35:24 PM |
To reformat the returned object, use formatDateTime.
ATL in Script | Result |
---|---|
| 2nd December 2021 |