Parsing XML in Windows Phone 7
Let's go back to the application that we are building in Visual Studio. First, change siteUrl
in the MainPage.xaml.cs
file to the RSS Feed URL that we got from our list.
private string siteUrl = "http://ssps2010/chapter6/_layouts/listfeed.aspx?List=%7BD45848A1%2D12E8%2D4722%2DAB5B%2D511BF802F8D8%7D&Source=http%3A%2F%2Fssps2010%2Fchapter6%2FLists%2FEngineering%2520Notes%2FAllItems%2Easpx";
Now, rerun the application in the emulator and the raw XML from the RSS feed will appear in the text block. Now that we have the XML feed in a string, we should display it in a more meaningful way. To do that, let's do the following:
- Replace the text block display with a listbox
- Create a simple view model for an RSS Item
- Parse the ...
Get Microsoft SharePoint 2010 Developer Compendium now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.