How to get current regional settings in C#?

前端 未结 7 1684
独厮守ぢ
独厮守ぢ 2020-11-29 08:32

Normally you can get it by writing something like

CultureInfo currentCulture = Thread.CurrentThread.CurrentCulture;

But this way you can only ge

7条回答
  •  孤街浪徒
    2020-11-29 08:48

    We ran into to this issue with our WinForms app and it was due to Visual Studio creating the [MyApp].vshost.exe process that is always running in the background whenever Visual Studio is open.

    Turning off the MyApp -> Properties -> Debug -> "Enable Visual Studio hosting process" setting fixed this for us.

    The vshost process is mainly used to improve debugging, but if you don't want disable the setting, you can kill the process as needed.

提交回复
热议问题