473,406 Members | 2,208 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

How to compile a UTF-8 resource file

Hello, All.

I have a UTF-8 resource file which contrains all the
translatable strings. when I compile it, I will get "RC :
fatal error RC1205 : invalid code page". Here is the
command I used:

rc /x /v /cUTF-8 testResource.rc

Can someone tell me what is the valid code page for "UTF-
8" or point me to the right place where I can look it up
myself?

Thanks very much,
Zheng Huang

Jul 19 '05 #1
3 4114
> I have a UTF-8 resource file which contrains all the
translatable strings. when I compile it, I will get "RC :
fatal error RC1205 : invalid code page". Here is the
command I used:

rc /x /v /cUTF-8 testResource.rc


The resource compiler does not support UTF8.
It does support UTF16 with BOM though.
Without parameters, it will detect the BOM (byte oder mark).

Mihai
Jul 19 '05 #2
Thanks, Mihai, for your tips.

When I use the compiled resoure file (UTF-16), VB still
does not display the Swedish character correctly. I have a
character ä in the resource file. When I use "MsgBox
(LoadResString(100)), it displays ä .
Can you tell me what I am missing?

Thanks in advance,
Zheng

-----Original Message-----
I have a UTF-8 resource file which contrains all the
translatable strings. when I compile it, I will get "RC : fatal error RC1205 : invalid code page". Here is the
command I used:

rc /x /v /cUTF-8 testResource.rc
The resource compiler does not support UTF8.
It does support UTF16 with BOM though.
Without parameters, it will detect the BOM (byte oder

mark).
Mihai
.

Jul 19 '05 #3

ä encoded as UTF8 is ä
It looks like you RC file is UTF8, then you compile it as ANSI.

Make sure you save it as UTF16
(from Notepad select "Save as..." and chose Unicode as file type)
Then compile using
/l 0x41d (to indicate Swedish)
No need to use /c, the BOM added by Notepad will do the trick

Another option, if you want Swedish, is to use the 1252 encoding,
the ANSI one for Swedish.
(from Notepad select "Save as..." and chose Text as file type)
Then compile it using
/c 1252 (to indicate the code page)
and
/l 0x41d (to indicate Swedish)

Mihai
Jul 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: lawrence | last post by:
Someone on www.php.net suggested using a seems_utf8() method to test text for UTF-8 character encoding but didn't specify how to write such a method. Can anyone suggest a test that might work?...
2
by: Denis S. Otkidach | last post by:
I have 2 questions about compile 1. What is the reason to encode source code to utf-8? I guess "python -U" behavior is the best choice in this case. The following snippet seems to fix this,...
8
by: janeaustine50 | last post by:
Python's InteractiveInterpreter uses the built-in compile function. According to the ref. manual, it doesn't seem to concern about the encoding of the source string. When I hand in an unicode...
38
by: Haines Brown | last post by:
I'm having trouble finding the character entity for the French abbreviation for "number" (capital N followed by a small supercript o, period). My references are not listing it. Where would I...
2
by: Ashabul Yeameen | last post by:
Hi all, I am writing a C program which at some certain steps needs to use the wide character funcion fputwc() for giving utf-8 output. Since I want to make the code more portable, I wrote my own...
3
by: Michael Kellogg | last post by:
In my project's "AssemblyInfo.vb" file, I have set the following for versioning: <Assembly: AssemblyVersion("3.0.*")> Yet every time I rebuild, I get the exact same build number and private...
3
by: sachinvyas | last post by:
Hi, I have following schema saved in new.xsd <?xml version="1.0" encoding="utf-8"?> <xs:schema targetNamespace="http://www.smpte-ra.org/schemas/429.7/2006/CPL"...
3
by: karthi | last post by:
Hi, I want to know how to compile socket programs in c
23
by: Allan Ebdrup | last post by:
I hava an ajax web application where i hvae problems with UTF-8 encoding oc chineese chars. My Ajax webapplication runs in a HTML page that is UTF-8 Encoded. I copy and paste some chineese chars...
1
by: msarora | last post by:
I'm using SimpleTransform.java (renamed as ReceiptTransformer.java for custom use) found in xalan-j_2_7_0 samples directory for transformations in my custom application. The program compiles...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.