WindowsApi:NationalLanguageSupport
lastmod 2018-08-17created 2016-12-0610 edits
GetACP
- [https://msdn.microsoft.com/en-us/library/windows/desktop/dd318070(v=vs.85.aspx MSND - GetACP]
- Stackoverflow - How can I programmatically determine the current default codepage of Windows?
Retrieves the current Windows ANSI code page identifier for the operating system.
Caution
The ANSI API functions, for example, the ANSI version of TextOut, implicitly use GetACP to translate text to or from Unicode. For the Multilingual User Interface (MUI) edition of Windows, the system ACP might not cover all code points in the user's selected logon language identifier. For compatibility with this edition, your application should avoid calls that depend on GetACP either implicitly or explicitly, as this function can cause some locales to display text as question marks. Instead, the application should use the Unicode API functions directly, for example, the Unicode version of TextOut.
| INFORMATION |
| ANSI API functions (e.g. the ANSI version of TextOut) implicitly use GetACP to convert text to Unicode or from Unicode to text. |
GetOEMCP
- [https://msdn.microsoft.com/en-us/library/windows/desktop/dd318101(v=vs.85.aspx MSDN - GetOEMCP]
Retrieves information about a locale specified by identifier.
CP_ACP vs CP_OEMCP
See also
Favorite site
- Stackoverflow - Can I get a code page from a language preference?
- Understanding the character encodings used in Windows 1
- The true nature of Unicode Windows 2