protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
GridViewRow row = new GridViewRow(-1, -1, DataControlRowType.EmptyDataRow, DataControlRowState.Normal);
TableCell cell = new TableCell();
cell.Text = "测试一下看行不行!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!";
cell.Attributes.Add("colspan", "4");
row.Cells.Add(cell);
GridView1.Controls[0].Controls.AddAt(e.Row.RowIndex+1, row);
}
}
GridView 手动添加一行
最新推荐文章于 2023-01-26 20:39:56 发布