日期:2014-05-17 浏览次数:20838 次
<?xml version="1.0" encoding="utf-8"?> <Rules> <Node 转换率="1" /> </Rules>
XmlDocument xmldoc = new XmlDocument();
xmldoc.Load("***.xml");
XmlNode root = xmldoc.SelectSingleNode("Rules");
((XmlElement)root.SelectSingleNode("Node")).SetAttribute("转换率", "1");
xmldoc.Save("***.xml");