一个控制GridView标题头的方法 protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e) { int i = e.Row.RowIndex; //索引为-1行为GridView头 if (i == -1) { e.Row.Cells[0].Text = "修改"; } }