SyntaxFix
Write A Post
Hire A Developer
Questions
There's a much simpler way to convert your XmlDocument to a string; use the OuterXml property. The OuterXml property returns a string version of the xml.
public string GetXMLAsString(XmlDocument myxml) { return myxml.OuterXml; }