I need to figure out if user is on Windows XP, and which service pack.
I use Get System Information(Service Pack Number) to get the service pack number, but I'm unsure what to use to tell if user is on a Window XP OS ?
Printable View
I need to figure out if user is on Windows XP, and which service pack.
I use Get System Information(Service Pack Number) to get the service pack number, but I'm unsure what to use to tell if user is on a Window XP OS ?
Hello,
You have several options here. The easiest one (IMO) is to check the %WINVER% variable value. If the value is $WINXP$ (see Common Definitions.sbi) then the machine is running XP.
So you can use:
If %WINVER% Equals "$WINXP$" Then
you are running xp
End
Does this help?
Thanks!
Is it also possible to get the language of the Windows install? (Not current selected language, but which language version of the OS was installed)
Hello,
Yes, please try the %CURLNG% variable. It returns the currently active Windows language ID.
Does this help?
BTW, another cool way is to use Get File Information (File Language) on kernel32.dll ;-)
For example:
Set Variable %OSLANGUAGE% to ScriptItem->Get File Information(File Language (Resource)) of file "%SYS32DIR%\kernel32.dll"
This returns 1044 for me, which is according to your manual: Norwegian (Bokmal) 1044
Now, my current language setting in Windows IS 1044 Norwegian, but my Windows installation is in English. And this is what I need to find out..
My second idea should work because it returns the language used to compile that Windows version :)
Yes, it worked. Didn't see that reply before I had sent the answer :) You're too fast Friedrich :)
<G> Thank you :)
Friedrich