Hi,
I have some problem to load an xml (string) in my IXMLDOMDocument. It's probably a problem of namespace but I don't know how to solve it!
what I try to make:
IXMLDOMDocument AVxml = (IXMLDOMDocument)thisXDocument.CreateDOM();
AVxml.loadXML("<AV xmlns='' xmlns:tsd=
'http://namespaces.softwareag.com/tamino/TaminoSchemaDefinition'
xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
<AVel >
<Title>Statutendatum</Title>
<Date xsi:nil='true'/>
</AVel>
</AV>");
I have try with IXMLDOMDocument3:
IXMLDOMDocument3 xmldoc = (IXMLDOMDocument3)thisXDocument.CreateDOM();
xmldoc.setProperty("SelectionNamespaces",
"xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"");
xmldoc.loadXML(...);
But same result! This make me an error of parsing (see in debug mode with Visual studio):
quote:
- parseError = {Microsoft.Office.Interop.InfoPath.SemiTrust.IXMLDOMParseErrorWrapper}
errorCode = -1072897995
reason = "the xsi:nil attribut on « Date » element isn't
valid.\r\n"
I don't understand how to make for add the namespace if it's really this? Have you any idea?
My primary schema accept this! Because if I try to make a preview with Data file infopath accept and I can see the result!
So what I can make for correct this?
Thanks a lot
++
Thierry
Infopath 2007, Langage: C#2.0 (Modèle Objet 2003)
merci de lire ceci