i am trying to grab the TopicName how should i go after it and try different combination but somehow i am unable to get TopicName below is my source codee...
XmlDocument xdoc = new XmlDocument();//xml doc used for xml parsing xdoc.Load( "http://latestpackagingnews.blogspot.com/feeds/posts/default" );//loading XML in xml doc XmlNodeList xNodelst = xdoc.DocumentElement.SelectNodes("content");//reading node so that we can traverse thorugh the XML foreach (XmlNode xNode in xNodelst)//traversing XML { //litFeed.Text += "read"; } sample xml file
<content type="application/xml"> <CatalogItems xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="sitename.xsd"> <CatalogSource Acronym="ABC" OrganizationName="ABC Corporation" /> <CatalogItem Id="3212" CatalogUrl="urlname"> <ContentItem xmlns:content="sitename.xsd" TargetUrl="url"> <content:SelectionSpec ClassList="" ElementList="" /> <content:Language Value="eng" Scheme="ISO 639-2" /> <content:Source Acronym="ABC" OrganizationName="ABC Corporation" /> <content:Topics Scheme="ABC"> <content:Topic TopicName="Marketing" /> <content:Topic TopiccName="Coverage" /> </content:Topics> </ContentItem> </CatalogItem> </CatalogItems> </content>
CatalogItemnor content namespace in that xml.