my6solutions

asp .net, the social web & other distractions

 

Running Apps


PayPal - The safer, easier way to pay online!

Disclaimer

I am in no way affiliated with Microsoft or Google. I am just another developer trying to make a difference. All opinions and observations are usually my own.

Reading ATOM and RSS Feeds using ASP .NET

ASP .NET 3.5 now allows ATOM and RSS Feeds to be read without using any external libraries. This is achieved via the SyndicationFeed class. For example, to read from a URL

XmlReader reader = XmlReader.Create(feedUrl);
SyndicationFeed feed = SyndicationFeed.Load(reader);

This is not limited to URLs. XmlReader.Create() will take a String, Stream, TextReader, and XmlReader. 

 

Bookmark and Share

Tags:
Categories: ASP .NET
Permalink | Comments (0) | Post RSSRSS comment feed