all groups > dotnet xml > december 2003 >
You're in the

dotnet xml

group:

Convert DOMDocument to System.Xml.Document?


Convert DOMDocument to System.Xml.Document? Dean Slindee
12/7/2003 5:27:37 PM
dotnet xml:
Newbie question: Any easy way to convert a DOMDocument to a
System.Xml.Document?

Dim DOMDocument As DOMDocument40

to this

Dim xmlDoc As System.Xml.XmlDocument

Thanks,

Dean Slindee

Re: Convert DOMDocument to System.Xml.Document? Peter Rilling
12/7/2003 11:34:00 PM
The easiest way might be to output the XML from the DOMDocument (I can't
remember which property/method does this) and load it into the LoadXml
method on the XmlDocument object.

[quoted text, click to view]

Re: Convert DOMDocument to System.Xml.Document? Martin Honnen
12/8/2003 12:56:58 PM


[quoted text, click to view]

I don't understand why you need to use two different XML imlementations
in one application (after all the XML format should allow you to use any
parser) but it seems that
xmlDoc.LoadXml(DOMDocument.xml)
should work.

--

Martin Honnen
http://JavaScript.FAQTs.com/
Re: Convert DOMDocument to System.Xml.Document? Dean Slindee
12/8/2003 10:31:11 PM
Yes, that did the trick. By way of explanation: communicating with eBay is
done thru DOMDocument, but as a .NET developer I would prefer to use
system.xml as much as possible, so I want to convert from DOM up front.
Thanks.
Dean Slindee
[quoted text, click to view]

AddThis Social Bookmark Button