采用Gridview的OnRowDataBound属性
后台
protected void gvTranslateInfo_RowDataBound(object sender, GridViewRowEventArgs e)
{
if(e.Row.RowIndex>=0)
{
if(e.Row.RowType==DataControlRowType.DataRow)
{
e.Row.Cells[1].Text = "<a target=_blank href=\"http://wfweb.test.aspirecn.com/pzgl/page/WorkFlow/BBBY/BBBY_Default.aspx?sid=5&mid=184089&pid=" + e.Row.Cells[1].Text.ToString() + "&tid=5\">" + e.Row.Cells[1].Text.Replace("&lt;", "<").Replace("&gt;", ">") + "</a>";
}
}
}
时间: 2024-08-11 00:00:47