Listing Time Zone in C#

Introduction

Listing system time zone is  very is, use TimeZoneInfo which is used to represent system time zone. it comes under System Name space, see the bellow code how it works to List all the System Time Zone

static void Main(string[] args)

{

    foreach (TimeZoneInfo TimeZone in TimeZoneInfo.GetSystemTimeZones())

    Console.WriteLine(TimeZone.DisplayName);

    Console.ReadLine(); 

}

 
Please give the comment if this code helps your.

Ebook Download
View all
Learn
View all