How can I convert DataSet a to a DataReader?

anjum picture anjum · Aug 20, 2010 · Viewed 17.3k times · Source

How can I convert a DataSet to a DataReader?

Answer

Raghavendra Devraj picture Raghavendra Devraj · Feb 21, 2013

You can use the following code to change dataset to DataReader:

DataTableReader rd = ds.Tables[0].CreateDataReader();