Jump to content

International settings windows


Recommended Posts

I hope there is someone who can tell me how to solve my problem:

I would like to change the user locale settings + international settings in Windows 2K en XP.

I would like to do so programmaticaly and refrain from using send keys in conjunction with the control applet.

I would like to set al values under HKEY_CURRENT_USER\Control Panel\International

It contains defaults for all countries, although I am not aware where they come from. I would seem that I would need to directly access API's as and provide it with a country code/id in order to have it fill out all the values.

XP has in addition a GEOID in the registry, it contains a key 'nation' with a number reflecting to the selected location. On the basis of this info a lot of information can be obtained, also using an API as explained for VB

at http://vbnet.mvps.org/code/locale/enumsystemlocales.htm

Does any one have any suggestions, snippets to use to get these questions solved?

Thanks in advance!

Link to comment
Share on other sites

HI,

you acn set RegKey with Autoit. RegWrite()

Does this help?

MsgBox(0, "Your OS Language:", _Language())

Func _Language()
Select
    Case StringInStr("0413,0813", @OSLang)
        Return "Dutch"

    Case StringInStr("0409,0809,0c09,1009,1409,1809,1c09,2009,2409,2809,2c09,3009,3409", @OSLang)
        Return "English"

    Case StringInStr("040c,080c,0c0c,100c,140c,180c", @OSLang)
        Return "French"

    Case StringInStr("0407,0807,0c07,1007,1407", @OSLang)
        Return "German"

    Case StringInStr("0410,0810", @OSLang)
        Return "Italian"

    Case StringInStr("0414,0814", @OSLang)
        Return "Norwegian"

    Case StringInStr("0415", @OSLang)
        Return "Polish"

    Case StringInStr("0416,0816", @OSLang)
        Return "Portuguese"

    Case StringInStr("040a,080a,0c0a,100a,140a,180a,1c0a,200a,240a,280a,2c0a,300a,340a,380a,3c0a,400a,440a,480a,4c0a,5
00a", @OSLang)
        Return "Spanish"

    Case StringInStr("041d,081d", @OSLang)
        Return "Swedish"

    Case Else
        Return "Other (can determine with @OSLang directly"

    EndSelect
EndFunc

So long,

Mega

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

Mega,

Thanks for your response but this is not quiete what I had been looking for. I have been working on a lanuage switch for the OS and applications, so a one interface changes it all.

I did manage to have the OS language, Office and applications to switch using my application that changes a bunch of regkeys. So far it was not an issue and this works.

The problem comes when needing to change the user locale and/or GEOID. The user locale settings consist of a bunch of keys; valuta, time/date format, currency etc. etc. normally they are all changed using the control applet, by selecting a country. The GEOID something only found in XP also uses codes which can't be found unless one changes the value and read them from the registry.

So to avoid this I am looking for a method to select one option and change a number of registry keys to the defaults that come with my choice. This would be the same thing as going to the Interational applet and select a country which makes the changes. I know in XP you can send a file to the control applet which contains the international settings, which will than be applied. Unfortunatly this doesn't work in win2k.

Maybe there is a way to parse information into the 2k applet but I can't find any information on this.

The only work around I currently can think of would be to include all the possible registry values for each country and put this in the script, but this would be an awfull lot of code and work obtaining these values, while it should be possible to set this direclty into the system making use of build in routines.

thx ozbob

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...