Reena Jain replied to Priyanka
03-Sep-10 02:58 AM
Hi,
use the following code
protected void Combobox1_SelectedIndexChanged(object sender, EventArgs e)
{
//to send the your combox id in database to fatch name and other detail
SqlCommand cmdd = new SqlCommand("Select * table where studentid='" + Combobox1.selectedvalue + "'", LiveCon);
SqlDataAdapter adpp = new SqlDataAdapter(cmdd);
DataTable dtr = new DataTable();
adpp.Fill(dtr);
if (dtr.Rows.Count > 0)
{
textbox1.Text=dt.rows[0]["Name"].tostring();
}
}
hope this will help