如何在Win32中获取特定的TIME_ZONE_INFORMATION结构? [英] How do I get a specific TIME_ZONE_INFORMATION struct in Win32?
本文介绍了如何在Win32中获取特定的TIME_ZONE_INFORMATION结构?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
Win32 GetTimeZoneInformation函数返回您在系统控制面板中设置的本地时区。如何获得另一个特定的时区?有没有这样的电话?
The Win32 GetTimeZoneInformation function returns your systems local time zone as set up in the control panel. How do I get another specific time zone? Is there a call that does this?
Tony
推荐答案
这不同时区的信息是存储在注册表中,所以你必须从那里检索信息,并自己填充TIME_ZONE_INFORMATION结构。
According to this the information for the different timezones is stored in the registry, so you will have to retrieve the information from there and populate the TIME_ZONE_INFORMATION struct yourself.
从msdn文章引用
Remarks
Settings for each time zone are stored in the following registry key:
HKEY_LOCAL_MACHINE
SOFTWARE
Microsoft
Windows NT
CurrentVersion
Time Zones
time_zone_name
这篇关于如何在Win32中获取特定的TIME_ZONE_INFORMATION结构?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文