Home » questions » Creating and populating a dataset using VB.NET?

Creating and populating a dataset using VB.NET?

2006-08-01 20:08:17, Category: Programming & Design
I have the code to connect to a database. I want to know how to create a data adapter and a dataset(I use a sql database). I want to do this by writing the code and not in the design view. Thanks.

Answers

  1. Indian_Male

    On 2006-08-02 01:16:56


    Create a record set object using ADO DC Control. With that you can run your query like adodc.execute("Select ....") Once your query is executed, you can use FirstRecord, NextRecord methods to move in your recordset. Use adodc.Fields() or adodc.fields("") to retrive the fields.