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
How many major types of connection objects in ADO.NET?
How we can provide data to ado.net?
What is a sqldataadapter?
Explain how to pass multiple tables in datasets simultaneously?
What is difference between ado.net and asp net?
What are the main differences between classic ado and ado.net?
How can we serialize the dataset object?
What is the difference between executequery and executenonquery?
What is the advantage of ado.net?
Which is better ole db or odbc?
What is ado data control?
List the 4 common ado.net namespaces?
Why do we need ado.net?
What is the difference between data reader and data adapter?
What is a control toolbox?