← Prev in month ← Prev in thread
Next in thread → Next in month →

MXXMLWriter and encoding

From
Enrico Prosperi <>
To
Date
2002-11-06T17:40:31Z
ID
<>
Thread
MXXMLWriter and encoding
I would like to have an XML file with UTF-8 encode:
<?xml version="1.0" encoding="UTF-8"?>
...

When I use MXXMLWriter, the file XML is <?xml version="1.0" encoding="UTF-16"?>
Can I encode the file with UTF-8 format?
Thanks,
   Flavio


My code is like this but it doesn't work:
....
IMXWriterPtr pXMLWriter;		
HRESULT hr = pXMLWriter.CreateInstance(__uuidof(MSXML2::MXXMLWriter));
		
ISAXContentHandlerPtr pContentHandler;
pContentHandler=pXMLWriter;  

pXMLWriter->put_encoding( CComBSTR("UTF-8") );
....
← Prev in month ← Prev in thread
Next in thread → Next in month →