1. 程式人生 > >帶URL的XML解析方式

帶URL的XML解析方式

add body xsd manager clas pos pen turn table

XmlDocument xml = new XmlDocument(); xml.LoadXml(responseString); XmlNode root = xml.DocumentElement; XmlNamespaceManager nsp = new XmlNamespaceManager(xml.NameTable); nsp.AddNamespace("soapenv", "http://schemas.xmlsoap.org/soap/envelope/"); nsp.AddNamespace("ns2", "http://service.ws.webservice.sajt"); nsp.AddNamespace("ns1", "http://service.ws.webservice.sajt/xsd"); XmlNode root2 = root.SelectSingleNode("ns1:status", nsp); XmlNode root4 = root.SelectSingleNode("soapenv:Body", nsp); XmlNode root5 = root4.SelectSingleNode("ns2:saveDocumentResponse", nsp); XmlNode root6 = root5.SelectSingleNode("ns2:return", nsp); XmlNode root7 = root6.SelectSingleNode("ns1:status", nsp);

帶URL的XML解析方式