gridview模板列中的按钮如何获取值

2024-10-31 15:12:36
有1个网友回答
网友(1):





' /> />

....

protected void BtnClick(object sender,EventArgs e)
{
for (int i = 0; i < gridview1.Rows.Count; i++)
{
Lable lbl= (Lable )this.gridview.Row[i].FindControl("lbl1")
MessageBox(lbl.Text);
}

}