This function converts a string encoded with a specific code page to Unicode.
Header file: | Tnefapi.h |
Platforms: | H/PC 3.0 |
Windows CE versions: | 2.10 and later |
INT WINAPI TnefConvertToUnicode (UINT CodePage, DWORD dwFlags,
LPCSTR lpMultiByteStr, int cchMultiByte, LPWSTR lpWideCharStr,
int cchWideChar);
Code page |
Name |
Contains |
1250 | Windows 1250 | Central European languages |
1251 | Windows 1251 | Cyrillic |
1252 | Windows 1252 | Western European languages |
1253 | Windows 1253 | Greek |
1254 | Windows 1254 | Turkish |
1255 | Windows 1255 | Hebrew |
1256 | Windows 1256 | Arabic |
1257 | Windows 1257 | Baltic languages |
1258 | Windows 1258 | Vietnamese |
20866 | KOI8-R | Russian Cyrillic standard |
21886 | KOI8-U | Ukrainian Cyrillic standard |
28592 | ISO 8859-2 | Central European languages |
28593 | ISO 8859-3 | Esperanto/Galician/Maltese/ incomplete Turkish |
28594 | ISO 8859-4 | Baltic languages |
28595 | ISO 8859-5 | Cyrillic |
28596 | ISO 8859-6 | Arabic |
28597 | ISO 8859-7 | Greek |
28598 | ISO 8859-8 | Hebrew |
28599 | ISO 8859-9 | Turkish |
28600 | ISO 8859-10 | Nordic languages, except Skolt Sami |
28604 | ISO 8859-14 | Celtic |
28605 | ISO 8859-15 | Western Europe, updated |
65000 | UTF-7 | 7-bit Unicode encoding |
65001 | UTF-8 | 8-bit Unicode encoding |
The function’s default behavior is to translate to the precomposed form. If a precomposed form does not exist, the function attempts to translate to a composite form.
The flags MB_PRECOMPOSED and MB_COMPOSITE are mutually exclusive. The MB_USEGLYPHCHARS flag and the MB_ERR_INVALID_CHARS can be set regardless of the state of the other flags.
The number of characters copied to the output buffer indicates success. If the output buffer size is 0, the function returns the size of the buffer required to contain the output string. Zero indicates failure.
ModifiedUTF7ToUnicode, UnicodeToModifiedUTF7