1、xmldocument 声名<xml version="1.0" encoding="UTF-8">
XmlDocument doc = new XmlDocument();
XmlDeclaration declaration = doc.CreateXmlDeclaration("1.0", "UTF-8", null);
doc.AppendChild(declaration);
2、添加根节点或节点
XmlElement rootXE = doc.CreateElement("HandleResult");//处理报文
doc.AppendChild(rootXE);