Programming Tips - How do I convert Big5 (Traditional Chinese) text to Unicode?

Date: 2003Oct2 Platform: win32 Language: C/C++ Q. How do I convert Big5 (Traditional Chinese) text to Unicode? A. Do this:
MultiByteToWideChar(950, ...);
950 is the Windows code page number for Big5. For example:
#ifndef CP_BIG5 #define CP_BIG5 (950) #endif wchar_t szTextW[1024]; MultiByteToWideChar(CP_BIG5, 0, szBig5, -1, szTextW, sizeof(szTextW));