获取当前系统中的时区

 

using System;
using System.Collections.ObjectModel;
using System.Linq;

namespace ConsoleApplication1
{
    class Program
    {
        private static void Main(string[] args)
        {
            try
            {
                ReadOnlyCollection<TimeZoneInfo> zones = TimeZoneInfo.GetSystemTimeZones();
                Console.WriteLine("The local system has the following {0} time zones", zones.Count);
                var result = zones.OrderBy(x => x.Id);

                foreach (var item in result)
                {
                    Console.WriteLine("{0}  {1}", item.Id, item);
                }
            }
            catch (Exception ex)
            {
                while (ex != null)
                {
                    Console.WriteLine(ex.Message);
                    ex = ex.InnerException;
                }
            }
            Console.ReadLine();
        }
    }

}

结果

The local system has the following 102 time zones
Afghanistan Standard Time (UTC+04:30)喀布尔
Alaskan Standard Time (UTC-09:00)阿拉斯加
Arab Standard Time (UTC+03:00)科威特,利雅得
Arabian Standard Time (UTC+04:00)阿布扎比,马斯喀特
Arabic Standard Time (UTC+03:00)巴格达
Argentina Standard Time (UTC-03:00)布宜诺斯艾利斯
Atlantic Standard Time (UTC-04:00)大西洋时间(加拿大)
AUS Central Standard Time (UTC+09:30)达尔文
AUS Eastern Standard Time (UTC+10:00)堪培拉,墨尔本,悉尼
Azerbaijan Standard Time (UTC+04:00)巴库
Azores Standard Time (UTC-01:00)亚速尔群岛
Bahia Standard Time (UTC-03:00)萨尔瓦多
Bangladesh Standard Time (UTC+06:00)达卡
Canada Central Standard Time (UTC-06:00)萨斯喀彻温
Cape Verde Standard Time (UTC-01:00)佛得角群岛
Caucasus Standard Time (UTC+04:00)埃里温
Cen. Australia Standard Time (UTC+09:30)阿德莱德
Central America Standard Time (UTC-06:00)中美洲
Central Asia Standard Time (UTC+06:00)阿斯塔纳
Central Brazilian Standard Time (UTC-04:00)库亚巴
Central Europe Standard Time (UTC+01:00)贝尔格莱德,布拉迪斯拉发,布达佩斯,卢
布尔雅那,布拉格
Central European Standard Time (UTC+01:00)萨拉热窝,斯科普里,华沙,萨格勒布
Central Pacific Standard Time (UTC+11:00)所罗门群岛,新喀里多尼亚
Central Standard Time (UTC-06:00)中部时间(美国和加拿大)
Central Standard Time (Mexico) (UTC-06:00)瓜达拉哈拉,墨西哥城,蒙特雷
China Standard Time (UTC+08:00)北京,重庆,香港特别行政区,乌鲁木齐
Dateline Standard Time (UTC-12:00)国际日期变更线西
E. Africa Standard Time (UTC+03:00)内罗毕
E. Australia Standard Time (UTC+10:00)布里斯班
E. Europe Standard Time (UTC+02:00)东欧
E. South America Standard Time (UTC-03:00)巴西利亚
Eastern Standard Time (UTC-05:00)东部时间(美国和加拿大)
Egypt Standard Time (UTC+02:00)开罗
Ekaterinburg Standard Time (UTC+06:00)叶卡捷琳堡
Fiji Standard Time (UTC+12:00)斐济
FLE Standard Time (UTC+02:00)赫尔辛基,基辅,里加,索非亚,塔林,维尔纽斯
Georgian Standard Time (UTC+04:00)第比利斯
GMT Standard Time (UTC)都柏林,爱丁堡,里斯本,伦敦
Greenland Standard Time (UTC-03:00)格陵兰
Greenwich Standard Time (UTC)蒙罗维亚,雷克雅未克
GTB Standard Time (UTC+02:00)雅典,布加勒斯特
Hawaiian Standard Time (UTC-10:00)夏威夷
India Standard Time (UTC+05:30)钦奈,加尔各答,孟买,新德里
Iran Standard Time (UTC+03:30)德黑兰
Israel Standard Time (UTC+02:00)耶路撒冷
Jordan Standard Time (UTC+03:00)安曼
Kaliningrad Standard Time (UTC+03:00)加里宁格勒,明斯克
Kamchatka Standard Time (UTC+12:00)彼得罗巴甫洛夫斯克-堪察加 - 旧用
Korea Standard Time (UTC+09:00)首尔
Libya Standard Time (UTC+01:00) 的黎波里
Magadan Standard Time (UTC+12:00)马加丹
Mauritius Standard Time (UTC+04:00)路易港
Mid-Atlantic Standard Time (UTC-02:00)中大西洋
Middle East Standard Time (UTC+02:00)贝鲁特
Montevideo Standard Time (UTC-03:00)蒙得维的亚
Morocco Standard Time (UTC)卡萨布兰卡
Mountain Standard Time (UTC-07:00)山地时间(美国和加拿大)
Mountain Standard Time (Mexico) (UTC-07:00)奇瓦瓦,拉巴斯,马萨特兰
Myanmar Standard Time (UTC+06:30)仰光
N. Central Asia Standard Time (UTC+07:00)新西伯利亚
Namibia Standard Time (UTC+01:00)温得和克
Nepal Standard Time (UTC+05:45)加德满都
New Zealand Standard Time (UTC+12:00)奥克兰,惠灵顿
Newfoundland Standard Time (UTC-03:30)纽芬兰
North Asia East Standard Time (UTC+09:00)伊尔库茨克
North Asia Standard Time (UTC+08:00)克拉斯诺亚尔斯克
Pacific SA Standard Time (UTC-04:00)圣地亚哥
Pacific Standard Time (UTC-08:00)太平洋时间(美国和加拿大)
Pacific Standard Time (Mexico) (UTC-08:00)下加利福尼亚州
Pakistan Standard Time (UTC+05:00)伊斯兰堡,卡拉奇
Paraguay Standard Time (UTC-04:00)亚松森
Romance Standard Time (UTC+01:00)布鲁塞尔,哥本哈根,马德里,巴黎
Russian Standard Time (UTC+04:00)莫斯科,圣彼得堡,伏尔加格勒
SA Eastern Standard Time (UTC-03:00)卡宴,福塔雷萨
SA Pacific Standard Time (UTC-05:00)波哥大,利马,基多
SA Western Standard Time (UTC-04:00)乔治敦,拉巴斯,马瑙斯,圣胡安
Samoa Standard Time (UTC+13:00)萨摩亚群岛
SE Asia Standard Time (UTC+07:00)曼谷,河内,雅加达
Singapore Standard Time (UTC+08:00)吉隆坡,新加坡
South Africa Standard Time (UTC+02:00)哈拉雷,比勒陀利亚
Sri Lanka Standard Time (UTC+05:30)斯里加亚渥登普拉
Syria Standard Time (UTC+02:00)大马士革
Taipei Standard Time (UTC+08:00)台北
Tasmania Standard Time (UTC+10:00)霍巴特
Tokyo Standard Time (UTC+09:00)大阪,札幌,东京
Tonga Standard Time (UTC+13:00)努库阿洛法
Turkey Standard Time (UTC+02:00)伊斯坦布尔
Ulaanbaatar Standard Time (UTC+08:00)乌兰巴托
US Eastern Standard Time (UTC-05:00)印地安那州(东部)
US Mountain Standard Time (UTC-07:00)亚利桑那
UTC (UTC)协调世界时
UTC+12 (UTC+12:00)协调世界时+12
UTC-02 (UTC-02:00)协调世界时-02
UTC-11 (UTC-11:00)协调世界时-11
Venezuela Standard Time (UTC-04:30)加拉加斯
Vladivostok Standard Time (UTC+11:00)符拉迪沃斯托克
W. Australia Standard Time (UTC+08:00)珀斯
W. Central Africa Standard Time (UTC+01:00)中非西部
W. Europe Standard Time (UTC+01:00)阿姆斯特丹,柏林,伯尔尼,罗马,斯德哥尔摩,
维也纳
West Asia Standard Time (UTC+05:00)阿什哈巴德,塔什干
West Pacific Standard Time (UTC+10:00)关岛,莫尔兹比港
Yakutsk Standard Time (UTC+10:00)雅库茨克

 

posted @ 2015-08-30 16:01  ChuckLu  阅读(4355)  评论(0编辑  收藏  举报