删除时的提示
请问这样为什么会报错? 指定的参数(e.Row.Cells[1].Controls[0])已超出有效值的范围。
参数名: index
if (e.Row.RowType == DataControlRowType.DataRow)
{
// 给删除按钮加提示
LinkButton btnDelete = (LinkButton)e.Row.Cells[1].Controls[0];
btnDelete.OnClientClick = "return confirm('您确定要删除此行吗?');";
}