@ToTime (Formula Language)

Converts a value with a data type of text or time to a date-time value.

Note: This @function is new with Release 6.


@ToTime( value )



Text, time, or list thereof. A value that cannot be converted returns the error, "The value cannot be converted to a Number."

Return value


The value converted to a time value.


This function is useful for ensuring that a value has a time data type before using it in functions that require time values as parameters.

If the parameter is a list, the function operates on each element of the list, and the return value is a list with the same number of elements. A failure occurs if any element cannot be converted.


  1. This example returns the time-date values 02/29/2008 and 03/01/2008 in a list.
    @ToTime("2/29/08" : "3/1/08")
  2. This code, when added to a field, converts the text value in the "date" field containing "08/29/01" into a time value and adds two days to the date. This function returns 08/31/01.
  3. This example, when added to an action button, displays the date two days after the date selected by a user in the "request" date-time field.