Skip to main content

DateToLocal

The DateToLocal function returns the time converted to a specific time zone local time.

Prototype

    DateToLocal( Date; DateType )

Arguments

    Date        Date      By value

A valid Date, an expression or a variable (Studio Only) that evaluates a Date.

DateType String By value

An empty or a valid string containing the selected time zone.

- Utc
- SFHub
- SFServer
- User

If not defined, the SFHub time zone will be applied.

Returns

    Date

The new Date parameter converted to locale time.

Exception

    Undefined

Undefined is returned if Date is Undefined or is not a Date.

Example

      DateToLocal( Date('052022'; ''), 'User' )