HOW TO FILL GRID VIEW WITH OUT USING SQLDATASOURCE AND
PROGRAMING?
Answer Posted / manumole
SqlConnection conn = new SqlConnection("Data
Source=MYSERVER;Initial Catalog=Northwind;User
Id=sa;Password=sa;");
conn.Open();
DataTable dt=new DataTable();
SqlDataAdapter da = new SqlDataAdapter("select
* from Employees", conn);
da.Fill(dt);
testGV.DataSource = dt;
| Is This Answer Correct ? | 15 Yes | 8 No |
Post New Answer View All Answers
how Sequence to connect and retrieve data from database using dataset?
What providers does Ado.net uses?
How do I delete a row from a DataTable?
What is ado.net code?
What is the difference between executenonquery () and executescalar ()?
Explain the advantages and disadvantages of using datalist?
Explain all the classes those are used for database connections between sql server and asp.net?
What is commandbuilder in ado.net?
How can we add relation between tables in a dataset?
describe the dataset object in ado.net.
Which control of the BindingNavigator returns the current position within the data source?
What are the steps you will take to improve performance? Will you use dataset or datareader?
Explain how to copy the contents from one table to another table and how to delete the source table in ado.net?
What is difference between datatable and dataset?
What is ado.net full form?