tags:

views:

72

answers:

2
+3  Q: 

Get country tld

Hello,

How do I programmatically get the system country tld. In the registry there's a key called sCountry which has the country's name, but in the system language, eg. If the user has the Spanish version sCountry would be Espana, German version would be Deutschland, etc.

A: 

Looks like LOCALE_SISO3166CTRYNAME is enough for what I need. Thanks

Pete Sampras
If that's the case, then please accept SamB's answer.
Nick Meyer
+1  A: 

Wikipedia says that the country-code TLDs are based on ISO 3166 with a few exceptions, so presumably GetLocaleInfo with an LCTYPE of LOCALE_SISO3166CTRYNAME would be useful for this. Oh, but you said that.

Why do you need this, anyway, if you don't mind my asking?

SamB