您的位置:首页 > 其它

gridview 模板里绑定多个参数

2011-10-28 15:48 274 查看
经常会遇到gridview绑定多个参数,头都大,简单点

protected void GridViewRowDataBound(object sender, GridViewRowEventArgs e)

{

if (e.Row.RowType == DataControlRowType.DataRow)

{

string url = "openNewWindow('ProductSell.aspx?id=" + e.Row.Cells[0].Text + "," + e.Row.Cells[4].Text + ",0')";

btnSell.Attributes.Add("onclick", url);

}

}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: