Times and Time Zones
In addition to the basic DateTime structure, the .NET Framework provides the following classes that support working with time zones:
Use this class to work with any time zone that is predefined on a system, to create new time zones, and to easily convert dates and times from one time zone to another. For new development, use the TimeZoneInfo class instead of the TimeZone class.
Use this structure to work with dates and times whose offset (or difference) from UTC is known. The DateTimeOffset structure combines a date and time value with that time's offset from UTC. Because of its relationship to UTC, an individual date and time value unambiguously identifies a single point in time. This makes a DateTimeOffset value more portable from one computer to another than a DateTime value.
This section provides the information that you need to work with time zones and to create time zone-aware applications that can convert dates and times from one time zone to another.
Discusses the terminology, concepts, and issues involved in creating time zone-aware applications.
Describes how to enumerate the time zones found on a local system.
Provides examples that enumerate the time zones defined in a computer's registry and that allow users to select a predefined time zone from a list.
Describes how to access Coordinated Universal Time and the local time zone.
Describes how to instantiate a TimeZoneInfo object from the local system registry.
Describes how to create a custom time zone that does not support the transition to and from daylight saving time.
Describes how to create a custom time zone that supports one or more transitions to and from daylight saving time.
Describes TimeZoneInfo support for serialization and deserialization of time zone data and illustrates some of the scenarios in which they can be used.
Describes how to create a custom time zone and save its information in a resource file.
Describes how to instantiate custom time zones that have been saved to an embedded resource file.
Discusses how to perform date and time arithmetic that reflects a time zone's adjustment rules.
Describes how to convert times from one time zone to another.
Describes how to resolve an ambiguous time by mapping it to the time zone's standard time.
Describes how to let a user determine the mapping between an ambiguous local time and Coordinated Universal Time.