Torgeir
Sat Jan 17 14:20:08 CST 2004
Jens Lenge wrote:
> when I alter the locale setting in a VBScript (SetLocale), will the change
> only be valid within that VBScript file or will it permanently change the
> computer's locale setting (even after the script is done)?
Hi
As Michael wrote, it's for the script instance only. Especially when writing a
script with a potential "international" use and that that deals with the
decimal symbol is some way or another, it is very important to use the
SetLocale to avoid errors (in the US, a period is used for the decimal symbol,
but e.g. in Norway it is a comma).
Here is an example on this:
http://groups.google.com/groups?selm=400730EC.F3E85283@hydro.com
In those type of situations, I try to always remember to put <SetLocale
"en-us"> in the script (and if I need to type the decimal symbol use a period),
some examples here:
http://groups.google.com/groups?as_epq=SetLocale%20en-us&as_ugroup=microsoft.public.*&as_uauthors=torgeir%20bakken
--
torgeir
Microsoft MVP Scripting and WMI, Porsgrunn Norway
Administration scripting examples and an ONLINE version of the 1328 page
Scripting Guide:
http://www.microsoft.com/technet/scriptcenter