KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
I am trying to read the data from XML File . In this elements are prefixed with 'app' and 'gml' text. because of these prefixes I am unable to read the data. For this I am trying to add namespace by using XMLNamespaceManager but not getting. Edit: XmlDocument xmlDoc = new XmlDocument(); xmlDoc.Load(new StringReader(strResult)); NameTable nt = new NameTable(); XmlNamespaceManager prefix = new XmlNamespaceManager(nt); string nmspc = xmlDoc.DocumentElement.NamespaceURI; prefix.AddNamespace("app:",xmlDoc.DocumentElement.NamespaceURI); prefix.PushScope(); Here the strResult contains <a href="http://www.weather.gov/forecasts/xml/SOAP_server/ndfdXMLclient.php?whichClient=GmlLatLonList&lat=&lon=&listLatLon=&lat1=&lon1=&lat2=&lon2=&resolutionSub=&listLat1=&listLon1=&l
Tags (comma-separated)
Save Edits
Cancel