views:

102

answers:

2

What are the possible solutions for finding the current active language which appears on the Windows language bar ?

+1  A: 

CultureInfo.CurrentCulture. This has information on the language and culture. If you just want the language name, try CultureInfo.CurrentCulture.ThreeLetterISOLanguageName.

RossFabricant
Do you know what is the non-.NET 3.5, regular Windows API alternative?
MaxVT
You should probably post this as it's own question.
EBGreen
+1  A: 

You should look at the Multilingual APIs in Win32 as a starting point. It's not entirely obvious from the documentation which call will provide you what you want, but I think the answer may lie with the calls relating to processes and threads, or preferred languages. You may need to do some experimentation to see which calls give the expected result of matching the language bar selection.

I suspect that the best call to try would be GetThreadUILanguage.

Jeff Yates