我想在C#
创建XML
文件,该文件在属性之一将得到另一个XML作为价值的价值:组XML作为XML节点属性
XmlDocument doc = new XmlDocument();
XmlElement nodElement = doc.CreateElement(string.Empty, "node", string.Empty);
nodElement.SetAttribute("text", MyXMLToInsert);
doc.AppendChild(nodElement);
MyXMLToInsert
将财产以后这样的:
<xml xmlns:o="urn:schemas-microsoft-com:office:office"
xmlns:w="urn:schemas-microsoft-com:office:word"
xmlns:m="http://schemas.microsoft.com/office/2004/12/omml"
xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=Content-Type content="text/html; charset=utf-8">
.
.
如何防止第二个XML的特殊字符不与主要字符冲突? 谢谢。