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
Give an example of a .net application which connects to microsoft access database using ado.net classes.
Explain how to call the sql commands asynchronously in ado.net version 2.0?
What are the Data providers in ADO.Net?
What is ole db query?
Explain the difference between an ado.net dataset and an ado recordset?
What is partial class?
Define data adapter?
What is the difference between SqlCommand and SqlCommandBuilder?
What is difference between connected and disconnected architecture in ado.net?
What are the advantages of ado.net?
What is sqldatareader?
How to retrieve the user id which is provided while windows authentication?
Explain how do you connect to sql server database without using sqlclient?
Which architecture does Datasets follow?
What is Data Provider?