A few days ago, I posted some general information about how multi-lingual development can be enabled in the Visual Studio IDE.
In response to that blog post, one customer posted a question asking about whether it is possible to launch the VS IDE with a command line switch to automatically start it with the desired UI language. The idea behind this is that a shortcut could be created for each user and they could start the IDE in their chosen language just by double-clicking the shortcut. I looked around on MSDN and found a command line switch that enables this type of scenario.
The /LCID command line switch can be used to specify the preferred UI language when launching the Visual Studio IDE. The LCID is the 4-digit language code corresponding to the language you want the UI to display in. For example, 1033 represents English. The command line will look something like the following, assuming you have Visual Studio 2005 and it is installed to the default location:
%ProgramFiles%\Microsoft Visual Studio 8\Common7\IDE\devenv.exe /LCID 1033
The value passed in via this switch gets propagated to the setting that you can view in the Tools | Options | Environment | International Settings preferences page. If you pass in an LCID value that represents a Visual Studio language that is not installed on your system, Visual Studio will automatically change it back to a default value.
You can find a partial list of LCID values in this MSDN article (unfortunately I could not find a comprehensive list). Note that the values listed in this table are in hexadecimal, and you will need to convert the value to decimal in order to pass it to the VS IDE via the /LCID command line switch. You can convert the value with the following steps:
- Click on the Start menu, choose Run and type calc to launch the Windows calculator
- Go to the View menu and choose Scientific
- Click the Hex radio button
- Type in the hex LCID value from the table
- Click the Dec radio button to convert the hex value to decimal