62,046
社区成员
发帖
与我相关
我的任务
分享
protected void Grid_CBZB_RowCreated(object sender, GridViewRowEventArgs e)
{
//判断创建的行是否为表头行
if (e.Row.RowType == DataControlRowType.Header)
{
//获取表头所在行的所有单元格
TableCellCollection tcHeader = e.Row.Cells;
//清除自动生成的表头
tcHeader.Clear();
//新添加的第一个表头单元格, 设置为合并7个列, 从而形成一行.
tcHeader.Add(new TableHeaderCell());
tcHeader[0].RowSpan = 2;
tcHeader[0].Text = "单位";
。。。。。。。。。。。
}