Doubt in getting LCID from Locale String 
Author Message
 Doubt in getting LCID from Locale String

Hello,

when i give Locale String(EN, DE, FR...), i need to get
win32 equivqlent value(9, 1031, 1036) in my ATL control.

for example

if ((strcpm(chLangTemp, "en") == 0)
      strLCID = 9;     // English

do have any windows standard method which gets Locale
("en") and returns equivalent LCID (ie 9 for english), if
any please update me.

Thanks in advance
Venkat



Tue, 01 Mar 2005 16:35:03 GMT  
 Doubt in getting LCID from Locale String
Doesn't seem to be any better way than enumerate all locales with
EnumSystemLocales, and for each one get the language code with
GetLocaleInfo(LOCALE_SABBREVLANGNAME) and compare it with the string you
have.
--
With best wishes,
    Igor Tandetnik

"For every complex problem, there is a solution that is simple, neat,
and wrong." H.L. Mencken


Quote:
> Hello,

> when i give Locale String(EN, DE, FR...), i need to get
> win32 equivqlent value(9, 1031, 1036) in my ATL control.

> for example

> if ((strcpm(chLangTemp, "en") == 0)
>       strLCID = 9;     // English

> do have any windows standard method which gets Locale
> ("en") and returns equivalent LCID (ie 9 for english), if
> any please update me.

> Thanks in advance
> Venkat



Wed, 02 Mar 2005 04:26:26 GMT  
 Doubt in getting LCID from Locale String
Hello,

   Thanks and can you give me a sample code for the same.
Again Thanks for your help.

Regs
Venkat

Original Message-----

Quote:
>Doesn't seem to be any better way than enumerate all
locales with
>EnumSystemLocales, and for each one get the language code
with
>GetLocaleInfo(LOCALE_SABBREVLANGNAME) and compare it with
the string you
>have.
>--
>With best wishes,
>    Igor Tandetnik

>"For every complex problem, there is a solution that is
simple, neat,
>and wrong." H.L. Mencken



>> Hello,

>> when i give Locale String(EN, DE, FR...), i need to get
>> win32 equivqlent value(9, 1031, 1036) in my ATL control.

>> for example

>> if ((strcpm(chLangTemp, "en") == 0)
>>       strLCID = 9;     // English

>> do have any windows standard method which gets Locale
>> ("en") and returns equivalent LCID (ie 9 for english),
if
>> any please update me.

>> Thanks in advance
>> Venkat

>.



Wed, 02 Mar 2005 13:17:58 GMT  
 Doubt in getting LCID from Locale String
Hello,
    Thanks for your help. It is working fine...

With Regs
Venkat

Quote:
>-----Original Message-----
>Hello,

>   Thanks and can you give me a sample code for the same.
>Again Thanks for your help.

>Regs
>Venkat

>Original Message-----
>>Doesn't seem to be any better way than enumerate all
>locales with
>>EnumSystemLocales, and for each one get the language
code
>with
>>GetLocaleInfo(LOCALE_SABBREVLANGNAME) and compare it
with
>the string you
>>have.
>>--
>>With best wishes,
>>    Igor Tandetnik

>>"For every complex problem, there is a solution that is
>simple, neat,
>>and wrong." H.L. Mencken



>>> Hello,

>>> when i give Locale String(EN, DE, FR...), i need to get
>>> win32 equivqlent value(9, 1031, 1036) in my ATL
control.

>>> for example

>>> if ((strcpm(chLangTemp, "en") == 0)
>>>       strLCID = 9;     // English

>>> do have any windows standard method which gets Locale
>>> ("en") and returns equivalent LCID (ie 9 for english),
>if
>>> any please update me.

>>> Thanks in advance
>>> Venkat

>>.

>.



Sat, 05 Mar 2005 11:37:55 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. Windows locale LCID and std::locale

2. HELP!!!!! Getting Locale information

3. Locale based string to float

4. Doubt about allocation of space of string

5. simple C++ string doubt

6. lcid problem and dual interfaces

7. Getting a String Out of a String Stream (ostringstream)

8. Getting Substring from String.LastIndexOf

9. A proposed replacement for gets (was: I/P of a string containing spaces)

10. A proposed replacement for gets (was: Input of a string containing spaces)

11. Getting string out of a function by reference.

12. Getting a char from a string

 

 
Powered by phpBB® Forum Software