????<asp:BoundColumn HeaderText="员工号"></asp:BoundColumn>

解决方案 »

  1.   

    在Datagird的PreRender事件写
    private void dgQuotation_PreRender(object sender, System.EventArgs e)
    {
    if (dgQuotation.Items.Count>0)
    {
    for (int i=0;i<dgQuotation.Items.Count;i++)
    {
                                //下面的Cell[x]里的x是第几列
    dgQuotation.Items[i].Cell[x].Text="";
    }
    }
    }
      

  2.   

    谢谢楼上的
    两个方法都可以
    不过还是不设datafield简单些还有一个问题:该表是要打印的,为了把整张纸占满,能否多显示些空行出来呢?
    现在查出一行显示一行