Time.From

Last updated 3 months ago

Time.From

Creates a time from the given value.

function (optional value as nullable any, optional culture as nullable any) as nullable any

Description

Returns a time value from the given value. If the given value is null, Time.From returns null. If the given value is time, value is returned. Values of the following types can be converted to a time value:

If value is of any other type, an error is returned.

Category

Time

Examples

Convert 0.7575 to a time value.

Time.From(0.7575)

time(18,10,48)

Convert #datetime(1899, 12, 30, 06, 45, 12) to a time value.

Time.From(#datetime(1899, 12, 30, 06, 45, 12))

time(06, 45, 12)