Functions

time

Supported By

Syntax

the [modifier] time

time ()

Modifier is short, abbreviated, long, or English. The default is short.

Example

put the time

Description

The time function returns a date representing the current time. There are three forms of the time function:

the short time or the abbrev time 12.34 PM
the long time 12.34.56 PM
the English time 12:34:56 PM

Notes

The format of the time is dependent on the current locale. This is important if you want to write scripts that work anywhere without modification. You cannot assume that the time function will always return a time in the same format.

To prevent issues caused by differing local time formats, use the seconds or the dateItems to store and perform calculations with dates and times.

See Also

convert, date, dateItems, seconds, ticks