Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write steps of retrieving data using ado.net ?

Answer Posted / sudheer lakkireddy

Take a gridview control in ur design
add
using system.data.sqlclient;
using.system.data;
// give a connection string to database

sqlconnection con= new sqlconnection("conn");

//in button click event write following

sqldataadapter da=new sqldataadapter("select * from
(tablename)",con);
dataset ds=new dataset();
da.fill(ds,"tablename");
gridview1.datasource=ds;
gridview1.datamember="tablename";
gridview1.databind();

try out this

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How many major types of connection objects in ADO.NET?

1035


How we can provide data to ado.net?

1044


What is a sqldataadapter?

998


Explain how to pass multiple tables in datasets simultaneously?

1039


What is difference between ado.net and asp net?

1041


What are the main differences between classic ado and ado.net?

1022


How can we serialize the dataset object?

1001


What is the difference between executequery and executenonquery?

912


What is the advantage of ado.net?

1017


Which is better ole db or odbc?

909


What is ado data control?

1001


List the 4 common ado.net namespaces?

1170


Why do we need ado.net?

967


What is the difference between data reader and data adapter?

1033


What is a control toolbox?

968