protected void GridView1_SelectedIndexChanged(object sender, EventArgs e) { string ma = GridView1.SelectedRow.Cells[0].Text; ng = cn.GetNganhByID(ma); if (ng != null) { txtMaNganh.Text = ng.MaNganh; txtTenNganh.Text = ng.TenNganh; txtSoTinChi.Text = ng.SoTinChi.ToString(); txtSoHocKi.Text = ng.SoHK.ToString(); ddlKhoa.SelectedValue = ng.MaKhoa; } }