1. <tfoot id='4rxrD'></tfoot>

          <bdo id='4rxrD'></bdo><ul id='4rxrD'></ul>
      1. <small id='4rxrD'></small><noframes id='4rxrD'>

        <i id='4rxrD'><tr id='4rxrD'><dt id='4rxrD'><q id='4rxrD'><span id='4rxrD'><b id='4rxrD'><form id='4rxrD'><ins id='4rxrD'></ins><ul id='4rxrD'></ul><sub id='4rxrD'></sub></form><legend id='4rxrD'></legend><bdo id='4rxrD'><pre id='4rxrD'><center id='4rxrD'></center></pre></bdo></b><th id='4rxrD'></th></span></q></dt></tr></i><div id='4rxrD'><tfoot id='4rxrD'></tfoot><dl id='4rxrD'><fieldset id='4rxrD'></fieldset></dl></div>
        <legend id='4rxrD'><style id='4rxrD'><dir id='4rxrD'><q id='4rxrD'></q></dir></style></legend>

        获取不同语言的系统时区

        时间:2023-10-07

          <bdo id='N6i5Y'></bdo><ul id='N6i5Y'></ul>
            <tbody id='N6i5Y'></tbody>
            <i id='N6i5Y'><tr id='N6i5Y'><dt id='N6i5Y'><q id='N6i5Y'><span id='N6i5Y'><b id='N6i5Y'><form id='N6i5Y'><ins id='N6i5Y'></ins><ul id='N6i5Y'></ul><sub id='N6i5Y'></sub></form><legend id='N6i5Y'></legend><bdo id='N6i5Y'><pre id='N6i5Y'><center id='N6i5Y'></center></pre></bdo></b><th id='N6i5Y'></th></span></q></dt></tr></i><div id='N6i5Y'><tfoot id='N6i5Y'></tfoot><dl id='N6i5Y'><fieldset id='N6i5Y'></fieldset></dl></div>
              1. <small id='N6i5Y'></small><noframes id='N6i5Y'>

                  <legend id='N6i5Y'><style id='N6i5Y'><dir id='N6i5Y'><q id='N6i5Y'></q></dir></style></legend>

                  <tfoot id='N6i5Y'></tfoot>
                  本文介绍了获取不同语言的系统时区的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我目前正在获取所有时区的列表,如下所示:

                  I'm currently getting the list of all timezones like this:

                  var TheListOfAllTimezones = TimeZoneInfo.GetSystemTimeZones();
                  

                  例如,巴黎的时区具有 W 的 DisplayName 属性.欧洲标准时间.现在我如何用另一种语言获得这个列表?例如,对于法国的用户,我想显示 Heure Europe de l'Ouest.

                  So for instance, the timezone in Paris has a DisplayName property of W. Europe Standard Time. Now how do I get this list in another language? For instance, for users in France, I'd like to display Heure Europe de l'Ouest.

                  谢谢.

                  推荐答案

                  更改 CurrentCulture 不起作用,因为信息来自注册表 (XP) 或多语言用户界面 (MUI) DLL(Vista、Windows 7).

                  Changing the CurrentCulture doesn't work as the information comes from the registry (XP) or from the Multilingual User Interface (MUI) DLL (Vista, Windows 7).

                  在 Vista 或 Windows 7 上,您可以安装其他语言并更改显示语言(区域和语言 -> 键盘和语言 -> 显示语言).需要重新启动.这个,也只有这个,实际上会改变 TimeZoneInfo 中使用的语言.

                  On Vista or Windows 7, you may install other languages and change the display language (Region and Language -> Keyboards and languages -> Display language). A reboot is required. This, and only this, will actually change the language used in TimeZoneInfo.

                  在 Windows 7 上,只有 Ultimate 和 Enterprise 允许安装其他语言 - 通过安装 多语言用户界面包.

                  On Windows 7, only Ultimate and Enterprise allow the installation of other languages - by means of installing Multilingual User Interface Packs.

                  安装其他语言后,您应该能够在 system32 文件夹中找到 DLL(查找 tzres),并可以使用 Visual Studio 导出资源.

                  Once you installed other languages, you should be able to find the DLLs in the system32 folder (look for tzres) and maybe export the resources with Visual Studio.

                  关于可信/官方来源 - BCL团队的一篇关于msdn的文章:

                  ...显示字符串从 Multilingual User 加载接口 (MUI) DLL、tzres.dll 或直接来自注册表,当MUI 支持不可用.支持 MUI 的操作系统,例如Windows Vista 包含 MUI_DisplayMUI_StdMUI_Dlt 键,它们由操作系统区域设置间接控制.在 Windows XP 和 Windows Server 2003 等下层平台上,只有 DisplayStdDlt 键存在.DisplayStdDlt键值仅本地化为操作的默认语言系统.

                  ...the display strings are loaded either from the Multilingual User Interface (MUI) DLL, tzres.dll, or straight from the registry, when MUI support is unavailable. MUI-enabled operating systems such as Windows Vista contain MUI_Display, MUI_Std, and MUI_Dlt keys, which are indirectly controlled by the operating systems regional settings. On down-level platforms such as Windows XP and Windows Server 2003, only the Display, Std, and Dlt keys exist. The Display, Std, and Dlt key values are localized only in the default language of the operating system.

                  那么他们对 CurrentUICulture 写了什么?

                  So what did they write about CurrentUICulture ?

                  由于 Windows 时区注册表架构,CurrentUICulture 设置不会影响这些值TimeZoneInfo 属性.

                  Because of the Windows time zone registry architecture, CurrentUICulture settings do not impact the values of these TimeZoneInfo properties.

                  这篇关于获取不同语言的系统时区的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:防止对 DateTime 值的反序列化进行时区转换 下一篇:使用拖放重新排序winforms列表框?

                  相关文章

                  <tfoot id='OwkGA'></tfoot>
                    <legend id='OwkGA'><style id='OwkGA'><dir id='OwkGA'><q id='OwkGA'></q></dir></style></legend>
                  1. <i id='OwkGA'><tr id='OwkGA'><dt id='OwkGA'><q id='OwkGA'><span id='OwkGA'><b id='OwkGA'><form id='OwkGA'><ins id='OwkGA'></ins><ul id='OwkGA'></ul><sub id='OwkGA'></sub></form><legend id='OwkGA'></legend><bdo id='OwkGA'><pre id='OwkGA'><center id='OwkGA'></center></pre></bdo></b><th id='OwkGA'></th></span></q></dt></tr></i><div id='OwkGA'><tfoot id='OwkGA'></tfoot><dl id='OwkGA'><fieldset id='OwkGA'></fieldset></dl></div>
                      <bdo id='OwkGA'></bdo><ul id='OwkGA'></ul>

                      <small id='OwkGA'></small><noframes id='OwkGA'>