Article ID: 108450
Article Last Modified on 7/11/2005
int MultiByteToWideChar(uCodePage, dwFlags, lpMultiByteStr,
cchMultiByte, lpWideCharStr, cchWideChar)
UINT uCodePage; /* codepage */
DWORD dwFlags; /* character-type options */
LPCSTR lpMultiByteStr; /* address of string to map */
int cchMultiByte; /* number of characters in string */
LPWSTR lpWideCharStr; /* address of wide-character buffer */
int cchWideChar; /* size of wide-character buffer */
The first parameter, uCodePage, specifies the codepage to be used when
performing the conversion. This discussion applies to the first parameter
of WideCharToMultiByte() as well. The codepage can be any valid codepage
number. It is a good idea to check this number with IsValidCodepage(), even
though MultiByteToWideChar() returns an error if an invalid codepage is
used. The codepage may also be one of the following values:
CP_ACP ANSI codepage CP_OEMCP OEM (original equipment manufacturer) codepageCP_ACP instructs the API to use the currently set default Windows ANSI codepage. CP_OEMCP instructs the API to use the currently set default OEM codepage.
Additional query words: 3.10 3.50
Keywords: KB108450