I need to generate a XML file, and I have its schema in XSD format.
I created the classes using the XML Data Binding Wizard, but:
One of the requirements is that the xml has the encoding tag set to 'utf-8'.
I've done it before when creating xml's directly with IXMLDocument, by doing this:
var xml:IXMLDocument;
.
.
xml.Encoding:='utf-8';
The XML first line becomes < ? xml version="1.0" encoding="utf-8" ? >
But now, with the data binding wizard, I tried something similar:
var xml:IXMLAuditFile;
.
.
xml.OwnerDocument.Encoding:='utf-8';
But that encoding isn't showing in then xml file: < ? xml version="1.0" ? >
Is there any other place I should be setting the encoding when using the XML Data Binding?
Thank you Nuno