I have create this code to change the color of row if item of endTimeStamp row equal to “0001-01-01 00:00:00.0000000” it change the row but also change the header I wan to ask how can I target the item row without the header
protected void gv_timesheet_RowDataBound(object sender, GridViewRowEventArgs e)
{
//To check condition on date time
if (Convert.ToDateTime(DataBinder.Eval(e.Row.DataItem, "endTimeStamp")) == Convert.ToDateTime("0001-01-01 00:00:00.0000000"))
{
e.Row.BackColor = System.Drawing.Color.Red;
}
}

You can add condition – based on
DataControlRowType.DataRow