Obtains the Current TimeZone (CTZ).
&TimeZone = DateTime.GetTimeZone()
Type Returned:
Timezone Domains
Note: The TimeZones domain doesn’t list all the possible Time Zone values. It may happen that the value returned by this method is not included in the domain.
Generators: .NET, .NET Framework, Java, Ruby (up to GeneXus X Evolution 3)
This is a static function of DateTime data type. Note that ‘DateTime’ is neither a variable nor an attribute; it’s the name of the DateTime data type to which the method is applied.
Event 'GetTZ'
&Timezones = DateTime.GetTimeZone()
msg(&Timezones.EnumerationDescription())
Endevent
When this is run in a browser in Uruguay, the following message will be displayed:
America/Montevideo
Enabling TimeZone Support
DateTime storage timezone property
SetTimeZone method
FromTimeZone method
CurrentOffset method