Author Posts

April 16, 2016 at 11:53 pm

I am just wondering what the class name is to find the regional settings of a Windows OS? I am using it for a report. I am preferring wmi because at the moment we have servers that are still using powershell v2 and they don't want to upgrade to the latest version just yet.

Any help appreciated.

April 17, 2016 at 3:23 am

I dont think you'll find it via wmi.
Regional data is stored in the registry per profile, not per computer.
You can look at the registry to get the data you want, it will be under hkey_current_user or hkey_users\ and then Control Panel\International

April 17, 2016 at 3:32 am

Win32_Operating system is probably your best bet, using the CountryCode, Locale and OSLanguage properties.

You'll probably want to translate the codes used into words (e.g. English_United_Kingdom is stored as 0809) but the lists are easy to find online and you can build a lookup table for your script.

April 17, 2016 at 5:42 am

Although country code might hint the regional, the locale and OSLangugae definitely dont relate to regional settings. I could have a Arabic locale windows and Arabic interface, but my regional would be Yemen, or Saudi Arabia, or others.