LINQ simplifies working with XML data & you need not use Xpath or XQuery for reading XML. This tip is about querying XML using LINQ.
This queries the XML & populates the listbox with values of Subject.
var books = from nodes in System.Xml.Linq.XElement.Load("Books.xml").Elements("Book") select nodes;
if (books != null)
foreach (var b in books)
I am a .Net developer working on C#,Asp.net,WCF,WF etc.I would like to utilize this space to share whatever I have come across so far working in .Net so that you can also learn & explore.
I hope you find these posts useful.I’d love to hear from you,so please post in your comments/feedback.
Visit my blog http://dotnetforyou.wordpress.com/
for more technical articles: