//根
/*保存参数*/
XmlDocument doc = new XmlDocument();
doc.LoadXml("<Parameters>" +
"</Parameters>");
//Create a new node.
XmlElement elemP = doc.CreateElement("ID");
elemP.InnerText="";
//Create a new node.
XmlElement elemType = doc.CreateElement("Type");
elemType.InnerText="INT";
XmlElement elemValue = doc.CreateElement("Value");
elemValue.InnerText="20";
//Add the node to the document.
XmlNode root = doc.FirstChild;
root.AppendChild(elemP);
root["ID"].AppendChild(elemType);
root["ID"].AppendChild(elemValue);