Hi there,

In my application, I need to get the code page for current IME device. For
example, if user selected Chinese in language bar, and keyed in Chinese
characters, I need to get code page 936 so I could translate the got key
code, which is in unicode. into double byte character set. And if user uses
Polish input method, my application should get 1250 as the code page.

I am using _getmbcp() to get code page for current locale, but not accurate
if the locale is English, but user is inputting other languages.

Any idea how to get the code page?

Thanks lot,

Re: How to get code page from current language input method? by Igor

Igor
Tue Oct 16 20:03:08 PDT 2007

"Gary" <Gary@discussions.microsoft.com> wrote in message
news:D49FAA80-924A-4320-B6B7-880AD43A9854@microsoft.com
> In my application, I need to get the code page for current IME
> device. For example, if user selected Chinese in language bar, and
> keyed in Chinese characters, I need to get code page 936 so I could
> translate the got key code, which is in unicode. into double byte
> character set. And if user uses Polish input method, my application
> should get 1250 as the code page.

TranslateCharsetInfo

http://blogs.msdn.com/michkap/archive/2006/08/28/728336.aspx

--
With best wishes,
Igor Tandetnik

With sufficient thrust, pigs fly just fine. However, this is not
necessarily a good idea. It is hard to be sure where they are going to
land, and it could be dangerous sitting under them as they fly
overhead. -- RFC 1925