作者fr730149 ()
看板C_Sharp
标题Re: [问题] gridview资料无法更新
时间Sat May 14 09:18:11 2011
从蓝色小舖的小喵得到解答:
在以下语法内,加入if判断式即可
: protected void gv_Main_Class_RowDataBound(object sender,
: GridViewRowEventArgs e)
: {
: if (e.Row.RowType == DataControlRowType.DataRow)
: {
: LinkButton d_button = (LinkButton)e.Row.Cells[0].FindControl("LinkButton4");
: Label ltext = (Label)e.Row.Cells[1].FindControl("Label1");
if ((d_button != null))
{
: d_button.OnClientClick = "return confirm('再一次确认,您确定要对
: 类别名称-- " + ltext.Text + " 的资料,进行处置动作吗?')";
}
: }
: }
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 116.118.161.39