INFO: Including RC File in Another RC File with a Different Codepage (264156)






This article was previously published under Q264156

SUMMARY

Including a .rc file within another .rc file may cause problems when the codepages in the two .rc files do not match. For example, if you include a Chinese resource file, Chsres.rc, in an English resource file, the combined resource file may not compile correctly (unless the resource file is on a Chinese platform). In the .rc file, if you do not provide a language and a #pragma statement, the system default is always used.

MORE INFORMATION

To avoid the problem, you must set the language and #pragma statement correctly before you include another .rc file. For example, in the English .rc file, add the following lines before you include the Chinese resource file:
LANGUAGE 04, 02
#pragma code_page(936)
#include "chsres.rc"
				

Modification Type: Minor Last Reviewed: 2/11/2004
Keywords: kbDSXGlobal2003Swept kbinfo kbLocalization kbNLS kbResource KB264156