Microsoft KB Archive/106065
Development Tools Do Not Accept Unicode Text
The information in this article applies to:
- Microsoft Win32 Software Development Kit (SDK), versions 3.1, 3.5
Neither the Win32 SDK tools or Visual C++ (VC++) 32-bit Edition tools support Unicode text. In fact, the C/C++ Language specification says that the source files are to be written in 7-bit ANSI.
For example, language-specific resources cannot be specified in Unicode in the .RC file because RC does not accept the Unicode text. Although the message compiler has flags for Unicode, the flags are not implemented.
To convert to and from Unicode text, use the UCONVERT utility included in your MSTOOLS\BIN directory. The source for UCONVERT in the 3.1 SDK is in MSTOOLS\SAMPLES\SDKTOOLS\UCONVERT. The source for UCONVERT in the 3.5 SDK is in MSTOOLS\SAMPLES\SDKTOOLS\WINNT\UCONVERT.
The long term solution that Microsoft is working on are Resource Localization Tools and other methods that will allow the user to localize the strings in a GUI editor, running on the target machine.
Note that it is possible to specify Unicode escapes in L-quoted strings. The following is quoted from "Common Statement Parameters" in RC.HLP:
By default, the characters listed between the double quotation marks are ANSI characters and escape sequences are interpreted as byte escape sequences. If the string is preceded by the L prefix, the string is a wide-character string and escape sequences are interpreted as two-byte escape sequences that specify Unicode characters. If a double quotation mark is required in the text, you must include the double quotation mark twice or use the \" escape sequence.
Another alternative is to use user-defined resources and include a binary (Unicode) file.
Additional query words: 3.10 3.50
Issue type :
Technology : kbWin32SDKSearch kbAudDeveloper kbSDKSearch kbWin32sSearch kbWin32SDK310 kbWin32SDK350
Last Reviewed: January 16, 2000