RSS

Force Regional Settings and Keyboard Settings with setlocale.exe

I wrote this a while ago for my wiki. I don’t use the wiki anymore as I don’t have nearly enough info and time to post good in depth technical articles. I find that the blog is a good place for shorter “tips” like this. Note that this was written before Group Policy Preference Extensions were distributed by MS, and that until everyone uses Preference extensions, this is still useful!

Force regional settings and keyboard language

From BinaryFactory

Contents

  • 1 Purpose of this article
  • 2 Why do this?
  • 3 Solution
  • 4 How to do it
    • 4.1 What is setlocale
    • 4.2 Extract setlocale.exe
      • 4.2.1 Make a script
      • 4.2.2 Apply the script

Purpose of this article

Centrally manage the keyboard language settings and/or the regional settings of your client computers or terminal servers/Citrix servers.

Why do this?

It seems Microsoft does not think that forcing a default Regional Setting or keyboard language policy is useful. However, many applications rely on the local date or number format, and using different settings on different client computers can cause a lot of problems. For Keyboard settings, it might be very useful to force a default for a group of users who have a locked down access to terminal server. You would think there is a way to do with with Group Policies, but as of Windows 2003 R2, there isn’t.

Solution

Use setlocale

How to do it

First, download this: setlocale

What is setlocale

Setlocale is a great command line application that does exactly what we need. I have uploaded it to this web site. However, I don’t know the license terms for it. The zip file I found contains a readme with no information about the author or the license. If you are the original author and want me to take it offline or link to your web site, please let me know. I tried to find the original author with no luck, but whoever you are: Thanks a lot.

Extract setlocale.exe

Extract setlocale.exe to a share that is readable by everyone. The location of your login scripts is usually a good spot.

Make a script

In the share where you usually put your login scripts, create a new one. Or if you already have a script applied to the users concerned by this, edit it. \\path\to\setlocale.exe 12345678 12345678

The first number represents the regional language you want to use, and the second one, the keyboard. For a complete list, refer to the readme in the zip file of setlocale.

Apply the script

Apply the script to the concerned users, group or O.U. Assigning login scripts is beyond the scope of this article.

No Comments | Tags: , , , , ,