Click here to Skip to main content
15,891,204 members

Comments by Madhuri P from Bombay Maharashtra, India (Top 1 by date)

SqlConnection Conn = new SqlConnection(Connection_String);
SqlCommand Comm1 = new SqlCommand(Command, Conn);
Conn.Open();
SqlDataReader DR1 = Comm1.ExecuteReader();
if (DR1.Read())
{
textBox.Text = DR1.GetValue(0).ToString();
}
Conn.Close();
This code works fine