Computer Hope

Microsoft => Microsoft DOS => Topic started by: almn on June 08, 2006, 03:41:43 PM

Title: Language
Post by: almn on June 08, 2006, 03:41:43 PM
Hello,

I would like to know how to find which version of xp the user is using(french,spanish,etc...)
then goto the :language .

For example:

find %langage%
if %language% ==fr goto fr
if %language% ==eng goto eng
if %language% ==spagoto spa
if %language% ==cn goto cn

OR

find %language%
goto %language%

:fr
echo nice job
pause
exit
:eng
echo nice job
pause
exit
:spa
echo nice job
pause
exit
:cn
echo sorry your language is not supported
pause
exit
:jap
echo sorry your language is not supported
pause
exit
:ger
echo sorry your language is not supported
pause
exit

Thank You

Almn
Title: Re: Language
Post by: GuruGary on June 08, 2006, 11:35:52 PM
I only have English Windows, so I don't have anything else to test with, but maybe you can try this?
Code: [Select]
@echo off
for /f "tokens=2*" %%a in ('reg query "hklm\SOFTWARE\Microsoft\Windows NT\CurrentVersion\WOW\boot.description" /v language.dll') do set language=%%b
echo Language is %language%
Title: Re: Language
Post by: almn on June 09, 2006, 04:59:52 AM
Great but that doesn't work  ;D
I am using XP French and it echos XP English  :-?

Thanks anyway

Almn
Title: Re: Language
Post by: almn on June 10, 2006, 10:50:39 AM
I think this echos the language of the keyboard  :-X

Almn