ADJUSTTIMEZONE
The ADJUSTTIMEZONE converts the input date/time/zone to the target time zone.
If the input doesn't specify a time zone, the local (unless overridden) time zone is used. If a format string is provided, the resulting time is formatted as specified
- Syntax:
- ADJUSTTIMEZONE (single-time expression, single-text expression [,single-text expression])
- Meaning:
- ADJUSTTIMEZONE (starting date/time, target time zone [, date_time_format_string])
- Returns:
- A single date-time
The ADJUSTTIMEZONE function returns the specified date and time, adjusted to the specified time zone, in the format specified by date_time_format_string, or with CCYYMMDDHHMMSS presentation if no date_time_format_string is provided. The date_time_string must conform to the date/time format strings as described in "Format strings"
Examples
StartDateTime = ADJUSTTIMEZONE (DateTime:Input, "America/Chicago"
In this example, StartDateTime is assigned the value of the input date and time, adjusted to the U.S Central time zone. Because ADJUSTTIMEZONE is assigned to an output, it is automatically converted to the presentation of StartDateTime. If the input date-time evaluates to 3:04pm Eastern time on 10/13/2020 and StartDateTime has a YYMMDDHH12MM presentation, the result is 2010130204
ADJUSTTIMEZONE (CurrentDateTime (), “+0100�?, "{MM.DD.CCYY HH24:MM}" )
In this example, the local current date and time is converted to Paris time and is returned in MM.DD.CCYY HH24:MM format. If it is currently 4:12 pm US Eastern time on October 13, 2020, the date returned would be 10.13.2020 22:12