草庐IT

userNode

全部标签

c# - 通过c#创建xml rootNode

我想像这样创建一个xml文档和根元素:我尝试这样创建:XmlDocumentdoc=newXmlDocument();XmlNoderootNode=doc.CreateElement("rdf:RDFxmlns:cim="http://iec.ch/TC57/2009/CIM-schema-cim14#"xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">");doc.AppendChild(rootNode);XmlNodeuserNode=doc.CreateElement("user");XmlAttributeatt