Quantcast
Channel: XML, System.Xml, MSXML and XmlLite forum
Viewing all articles
Browse latest Browse all 935

Find specific XML Nodes in httpwebresponse

$
0
0

Hello Guys,

http://s000.tinyupload.com/?file_id=07672783697545510627

I want to loop through the attached Httpwebresponse document to find below mentioned nodes in each <d:element/> node.

<d:Key>DocId</d:Key><d:Value>191713063</d:Value>

This is what i have tried so far. looking for efficient way to do this. Probably LINQ???

This is what i have tried so far:

XmlNamespaceManager nsmgr1 = new XmlNamespaceManager(ResultXML.NameTable);
            nsmgr1.AddNamespace("d", "http://schemas.microsoft.com/ado/2007/08/dataservices");

            XmlNodeList nodeList;
            XmlElement root = ResultXML.DocumentElement;
            nodeList = root.SelectNodes("//d:Rows", nsmgr1);
            foreach (XmlNode isbn in nodeList)
            {
                foreach (XmlNode childNode in isbn.ChildNodes)
                {
                    nodeList = childNode.SelectNodes("//d:element", nsmgr1);

                }

            }

Regards,


Thanks, Nilesh


Viewing all articles
Browse latest Browse all 935

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>