ASP.NET WS pass XMLNode to XMLDocument

In an ASP.NET WS, an XMLNode is passed in a function that is supposed to create an XML Document with the XMLNode and process it in the WS. I try different things like "XMLDocument.InnerXML =XMLNode.InnerXML", 'XMLDocument.AppendChild(XMLNode)", etc...but keep getting the following error:

The document does not have a root element

Please advise syntactically how to make the XML document take the XML node without the "root" error.
Thanks.
ksfokAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
Bob LearnedConnect With a Mentor Commented:
Try this:

Bob


using System.Xml;
 
...
 
XmlDocument document = new XmlDocument();
document.LoadXml(XMLNode.InnerXML);

Open in new window

0
All Courses

From novice to tech pro — start learning today.