TimeZone

From Xojo Documentation

Class (inherits from Object)


New in 2019r2

Used to identify a time zone in relationship to a Date.

Properties
Abbreviation fa-lock-32.png SecondsFromGMT fa-lock-32.png
Constructors

Constructor(gmtOffsetInSeconds As Integer)


Constructor(name As String)


Shared Methods
Current

Notes

Use any valid timezone. A list of common time zones is available here: https://en.wikipedia.org/wiki/List_of_tz_database_time_zones

Sample Code

Creates a DateTime for Berlin timezone that matches the local timezone's hours and minutes:

Var d As DateTime = DateTime.Now(New TimeZone("Europe/Berlin"))

See Also

DateTime class