TimeZone.CurrentTimeZone Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the time zone of the current computer.
public:
static property TimeZone ^ CurrentTimeZone { TimeZone ^ get(); };
public static TimeZone CurrentTimeZone { get; }
static member CurrentTimeZone : TimeZone
Public Shared ReadOnly Property CurrentTimeZone As TimeZone
Property Value
A TimeZone object that represents the current local time zone.
Remarks
The CurrentTimeZone property corresponds to the TimeZoneInfo.Local property. Whenever possible, use the TimeZoneInfo.Local property.
Notes to Callers
Local time zone data is cached after CurrentTimeZone is first used to retrieve time zone information. If the system's local time zone subsequently changes, the CurrentTimeZone property does not reflect this change. If you need to handle time zone changes while your application is running, use the TimeZoneInfo class and call its ClearCachedData() method.