Answer Posted / kalirajan
SqlConnection con = new SqlConnection("");
con.Open();
SqlCommand cmd = new SqlCommand("", con);
SqlDataReader dr;
dr = cmd.ExecuteReader();
while (dr.Read())
{
TextBox1.Text = dr[0].ToString();
}
dr.Close();
Try this code...
| Is This Answer Correct ? | 8 Yes | 8 No |
Post New Answer View All Answers
Which database is the ado.net?
What are the major difference between classic ADO and ADO.NET?
What provider ado.net use by default? Explain the role of data provider in ado.net? What is the role of data provider in ado.net?
What is a dataview?
What is the difference between Response.Expires and Reponse.ExpiresAbsolute?
What is XML serialization
How does ado.net work?
What is an example of ordinal data?
How would you connect to a database by using .NET?
What are the ado.net components?
What are the ado.net objects?
Data reader read and forward only, how is it possible to get 2 tables of data at a time?
What is the difference between Optimistic and Pessimistic locking?
What is sqldatareader?
How to identify the controls which can be used for binding data?