Author: dk3lan | Posted on: 1/24/2010 1:22:32 AM | Views : 255

I try select rows on datagridview bind to Textbox for edit, but not bind to Textbox. I don't understand
yours help me
code behind:
_________________

protected void GrdMem_SelectedIndexChanged(object sender, EventArgs e) { try { txtuser.Text = GrdMem.Rows[GrdMem.SelectedIndex].Cells[1].Text; txthoten.Text = GrdMem.Rows[GrdMem.SelectedIndex].Cells[2].Text; txtemail.Text = GrdMem.Rows[GrdMem.SelectedIndex].Cells[3].Text; txtdiachi.Text = GrdMem.Rows[GrdMem.SelectedIndex].Cells[4].Text; txtbirthday.Text = GrdMem.Rows[GrdMem.SelectedIndex].Cells[5].Text; txtdienthoai.Text = GrdMem.Rows[GrdMem.SelectedIndex].Cells[6].Text; } catch (Exception ex) { Response.Write(ex.Message.ToString()); }

Design view:

 Go to the complete details ...