[导入]C#操作XML文件(例2)

     摘要: //创建xml文件(添加根节点的属性)

StreamWriter sw = File.CreateText(AppDomain.CurrentDomain.BaseDirectory + "Xml\\" + xmlFilename + ".xml");

sw.WriteLine("");

sw.WriteLine("");

sw.Close();

XmlDocument doc = new XmlDocument();

doc.Load(AppDomain.CurrentDomain.BaseDirectory + "Xml\\" + xmlFilename + ".xml");

  阅读全文

寒夜听雨 2007-01-17 17:00 发表评论

文章来源:http://www.cnblogs.com/302soft/archive/2007/01/17/622926.html
posted @ 2007-03-27 21:17  evilyzou  阅读(168)  评论(0)    收藏  举报