Visual Studio and .NET Framework Home
RC file with characters outside ANSI code page is saved without warning, corrupting characters
5/12/2007 9:42:37 PM
User(s) can reproduce this bug
Resource Editor accepts text outside the ANSI code page, saves the RC without warning or error message, but the text is replaced by question marks.
This is a VS 2005 bug, still present in Orcas beta.
See also http://www.mihai-nita.net/article.php?artID=20051030a
Visual Studio Code Name "Orcas" (Beta 1)
Windows XP Professional
Operating System Language
Steps to Reproduce
Create MFC Dialog Application (everything default)
In the application dialog replace the text in the default label with some text outside the ANSI code page (ie Japanese on English US system, try 日本).
Save, build, and run
The text is replaced by question marks.
Open the .rc file in Notepad (or in VS IDE as code). The label really contains question marks.
The IDE should give an error message and offer to save as Unicode file (be at least as smart as Notepad :-)
TAP Code (if applicable)
You can indicate your satisfaction with how Microsoft handled this issue by completing this quick
3 question survey
to post a comment.
Please enter a comment.
on 5/25/2009 at 1:11 PM
The Visual C++ team has triaged the issue you reported. The issue has been resolved during triage with the following message:
The next release of Visual Studio produces resource files encoded in UTF-16LE which solve encoding problems. If you still use ANSI encoding and you want to use characters from outside ANSI code page you should convert resource file encoding to UTF-16LE. Thank you for your feedback.
For further information, you may want to consult one of these resources:
1. Visual C++ triage guidelines:
2. MSDN forums:
Thank you for taking time to send us feedback,
The Visual C++ Team
on 5/14/2007 at 10:51 PM
The important part is "Save, build, and *run*"
The text shows in the resource editor, but is not present in the .rc file (and at runtime).
The corect Unicode characters are in the .aps file.
on 5/13/2007 at 8:25 PM
Thanks for your feedback. We were unable to repro the bug with the steps provided using Win2003 SP2 and OrcasBeta1VSTS. At the dialog section of the .rc file, we replaced the text in the default label with the text ‘ 日本’. (LTEXT “日本”, IDC_STATIC,42,26,114,8) It was shown in the dialog correctly. If you still see this issue occurring we would like to investigate this issue again. Please provide a ZIP of an example project and more detailed steps, and we will re-investigate. Thank you, Visual Studio Product Team.
on 5/13/2007 at 4:21 PM
Thank you for your feedback. We are currently investigating. If this issue is urgent, please call support directly (see http://support.microsoft.com). Thank you, Visual Studio Product Team.
to post a workaround.
Please enter a workaround.
© 2014 Microsoft