The best way might be to get an XMLTranscoder for ISO-8859-1 and transcode
it via that. It will handle those high bit characters and pass the ASCII
subset through unchanged I think. So look at the TransService object which
is a static member of XMLPlatformUtils. Ask it to create you an
XMLTranscoder for the encoding you want, and use that transcoder to do the
work instead of XMLString (which BTW, isn't what you want ot use anyway
since it just transcodes to the local code page, so you'd be screwed if your
code ever had to run on say an EBCDIC machine.)

--------------
Dean Roddey
Software Geek Extraordinaire
Portal, Inc
[EMAIL PROTECTED]



-----Original Message-----
From: Jeremy Sheeley [mailto:[EMAIL PROTECTED]]
Sent: Thursday, March 22, 2001 12:16 PM
To: [EMAIL PROTECTED]
Subject: encoding problems


I'm working with version 1.4 of xerces and parsing WML files.  Looking
around the web, I found a page that causes xerces to behave unexpectedly.
The problem is that it's a straight ASCII file, but with one non-ASCII
character (the character's hex value is A2).  When I do a
XMLString::transcode() on any string that contains this A2 character, I get
back "h=@h=@n" instead of the string I expect.  Are there any ideas on how I
can get around this?  Any help would be appreciated.

-Jeremy Sheeley
SourceGear


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to