获取GridView控件上的值:
1)获取处于非编辑项的绑定文本: (gridview默认显示的样式 通过asp:boundfield绑定的)
GridView1.Rows[1].Cells[3].Text;
2)获取一个编辑状态的非模板项的数据: (通过asp:boundfield绑定的)
(GridView1.Rows[e.RowIndex].Cells[3].Controls[0]asTextBox).Text;
3)如果该列是模板列,统一使用FindControl根据id找到该控件(通过asp:TemplateField绑定的)
(GridView1.Rows[e.RowIndex].FindControl("txtName") as TextBox ).Text;