Ricardo,
You can try using the country information that is registered in the OS, I am no sure if it is the same as the one in "Regional Settings", in the quick test I just did, I changed my country To be "Ecuador" in it and the code still gave me "2" (Canada) as the country, so maybe it helps you, although it might also be that I changed the country in the wrong place, but you can easily test it.
The code would be something like this:
loLocator = CREATEOBJECT('WBEMScripting.SWBEMLocator')
loWMI = loLocator.ConnectServer()
loOSs = loWMI.ExecQuery('Select * from Win32_OperatingSystem where Primary=True')
for each loOS in loOSs
? 'Locale: ', loOS.Locale, 'Country Code:', loOS.CountryCode
endfor
where, from the help:
CountryCode
Data type: string
Access type: Read-only
Code for the country/region that an operating system uses. Values are based on international phone dialing prefixes—also referred to as IBM country/region codes. The property can use up to six characters to define the country/region code value.
Example: "1" (United States)
"The five senses obstruct or deform the apprehension of reality."
Jorge L. Borges?
"Premature optimization is the root of all evil in programming."
Donald Knuth, repeating C. A. R. Hoare
"To die for a religion is easier than to live it absolutely"
Jorge L. Borges