Sunday, June 14, 2009

XmlUrlDataSource sharepoint answer to XML based data

Scenario:
I was trying to bind one RSS feed to my grid and so started investigating and found another great control

Solution:
You can create a XMLUrlDataSource instance and bind it to grid.

Example:

 var source = new XmlUrlDataSource()
{
HttpMethod = "GET",
EnableCaching = true,
ErrorCacheDuration = 300,
CacheDuration = 0x1c20,
AuthType = "None",
SelectCommand = "http://feeds.feedburner.com/sandeepnahta",
XPath = ""
};



Follow me on Twitter

0 comments: