Re: [xsl] Character encoding in MSXML 3.0 from VB

Subject: Re: [xsl] Character encoding in MSXML 3.0 from VB
From: David Carlisle <davidc@xxxxxxxxx>
Date: Wed, 10 Jan 2001 10:14:39 GMT
> is there a standard/easy way to translate the window's character value
> to the unicode one? 

The best is to download

and read 100 lines every night before you go to bed. After a while
you'll just know all the numbers.

> i.e in windows if I type ALT-0145 this display the ' (open quote) how
> do I programmatically know to output this as &#8216; 

Ah this is a rather different issue. If you want to type alt-0145
then you will be entering that as character data (ie byte hex 145)
into the file, not &#145;. That is OK so long as you tell your XML
parser that you are using this encoding. Ie at the top put
<?xml version="1.0" encoding="xxxxx"?>

Now if you use an encoding other than utf-8 or utf-16 the XML parser is
allowed to reject the file as an unknown encoding. However assuming you
are on MS Windows, most parsers on that platform will presumably
understand these windows encodings.

I think in your case you want  encoding="xxxxx" to be encoding="windows-1252". 
But you might need to check exactly what names your parser calls these
windows encodings.

(You might also wonder why Windows takes the ISO encodings and
gratuitously shuffles the characters round:-)


This message has been checked for all known viruses by Star Internet delivered
through the MessageLabs Virus Control Centre. For further information visit

 XSL-List info and archive:

Current Thread