Jump to content

What's the best way to change Windows language settings using Autoit?


timmy2
 Share

Recommended Posts

To change the language used by Windows GUI and the browser (Chrome in my case), the only method I've found that works is to go to Settings > Time & Language > Language > Preferred Language, switch the default from English to Spanish, sign out, and then upon signing in everything will be in Spanish as expected.

Besides automating the above process is there a more direct way to change Windows' settings using AutoIt?

Link to comment
Share on other sites

I would try the registry way

Spoiler

[HKEY_CURRENT_USER\Software\Microsoft\CTF\SortOrder\Language]
"00000000"="00000409"
"00000001"="00000816"

[HKEY_CURRENT_USER\Control Panel\International]
"Locale"="00000816"
"LocaleName"="pt-PT"
"s1159"="AM"
"s2359"="PM"
"sCountry"="Portugal"
"sCurrency"="€"
"sDate"="/"
"sDecimal"=","
"sGrouping"="3;0"
"sLanguage"="PTG"
"sList"=";"
"sLongDate"="dddd, d' de 'MMMM' de 'yyyy"
"sMonDecimalSep"=","
"sMonGrouping"="3;0"
"sMonThousandSep"=" "
"sNativeDigits"="0123456789"
"sNegativeSign"="-"
"sPositiveSign"=""
"sShortDate"="dd/MM/yyyy"
"sThousand"=" "
"sTime"=":"
"sTimeFormat"="HH:mm:ss"
"sShortTime"="HH:mm"
"sYearMonth"="MMMM' de 'yyyy"
"iCalendarType"="1"
"iCountry"="351"
"iCurrDigits"="2"
"iCurrency"="3"
"iDate"="1"
"iDigits"="2"
"NumShape"="1"
"iFirstDayOfWeek"="6"
"iFirstWeekOfYear"="2"
"iLZero"="1"
"iMeasure"="0"
"iNegCurr"="8"
"iNegNumber"="1"
"iPaperSize"="9"
"iTime"="1"
"iTimePrefix"="0"
"iTLZero"="1"

[HKEY_CURRENT_USER\Control Panel\International\Geo]
"Nation"="193"

[HKEY_CURRENT_USER\Keyboard Layout\Preload]
"1"="00000816"

[HKEY_CURRENT_USER\Keyboard Layout\Toggle]
"Hotkey"="3"
"Language Hotkey"="3"
"Layout Hotkey"="3"

[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Nls\Language]
"InstallLanguage"="0409"
"Default"="0409"

[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet002\Control\Nls\Language]
"InstallLanguage"="0409"
"Default"="0409"

 

 

 

 

Spoiler

Renamer - Rename files and folders, remove portions of text from the filename etc.

GPO Tool - Export/Import Group policy settings.

MirrorDir - Synchronize/Backup/Mirror Folders

BeatsPlayer - Music player.

Params Tool - Right click an exe to see it's parameters or execute them.

String Trigger - Triggers pasting text or applications or internet links on specific strings.

Inconspicuous - Hide files in plain sight, not fully encrypted.

Regedit Control - Registry browsing history, quickly jump into any saved key.

Time4Shutdown - Write the time for shutdown in minutes.

Power Profiles Tool - Set a profile as active, delete, duplicate, export and import.

Finished Task Shutdown - Shuts down pc when specified window/Wndl/process closes.

NetworkSpeedShutdown - Shuts down pc if download speed goes under "X" Kb/s.

IUIAutomation - Topic with framework and examples

Au3Record.exe

Link to comment
Share on other sites

#include <WinAPISysWin.au3>
#include <WinAPISys.au3>
#include <SendMessage.au3>

Local $sLayoutID = xxxx
Local $ret = _WinAPI_LoadKeyboardLayout ($sLayoutID, $KLF_REPLACELANG)
_SendMessage ($hWnd, $WM_INPUTLANGCHANGEREQUEST, 1, $ret)

You can read registry to know what language you have preloaded

Link to comment
Share on other sites

  • 3 months later...

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

×
×
  • Create New...