I have the following code which takes a news feed from a remote website and loads it into a DataSet.
However I'm having problems when the feed times out - rather than throwing an error that is caught by the try catch block it just throws a time out error for the whole application.
How can I extend this so I can specify a time out for the XmlTextReader?Code:XmlTextReader _xmlReader = new XmlTextReader(ConfigurationSettings.AppSettings["NewsXmlFeedUrl"]); DataSet _dsStories = new DataSet(); _dsStories.ReadXml(_xmlReader);
Cheers
DJ





Reply With Quote