string tempPath = this.Request.PhysicalApplicationPath + "web.config";
            XmlDocument xd = new XmlDocument();
            xd.Load(tempPath);
            XmlNode xn = xd.SelectSingleNode("//add[@key='test']");//获取节点属性

  XmlNode xn = xd.SelectSingleNode("/configration/appSetting/add[@key='test']");
            Response.Write(xn.Attributes["value"].Value);

相关文章:

  • 2022-12-23
  • 2021-05-27
  • 2021-05-25
  • 2022-12-23
  • 2022-12-23
  • 2021-12-03
  • 2021-05-24
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案