How to pick data from dataset using C#.Net - Beginner C#.Net Tutorials.



Today i will explain how to pick data from DataSet using C#.NET.


In the Previous articles i explained how to close form on click of the button using C#.nethow to insert record into database from listview control using C#.nethow to backup and restore access database using c#.nethow to backup and restore access database using, how to fill dataset using and many more about C#.Net.

Below is the Code For Filling Dataset

 OleDbConnection con = new OleDbConnection("YourConnectionString");
            OleDbDataAdapter da = new OleDbDataAdapter("select * from table1", con);
            DataSet ds = new DataSet();

Create DataSet object.

And Fill DataSet using Fill Function. Pass DataSet object as parameter in Fill Function.


Now Next question is how to pick record from DataSet? You can use the Below code :       


Here we are picking title column from table which is on index no. 1.

Give your Valuable Comments.
comments powered by Disqus
Follow me on twitter
About Me
Harpreet Singh
I began programming with C++ when i was 17. Then at the middle of my study .NET came. Then I began to read C# and VB.NET. By the time i learnt SQL and ASP.NET, and developed some websites such as news portals that are active now. Currently i am running my own Software company.
More Articles