hii
i have grid view that show database from sqldatabase
i am using c# in visual studio
i want to calculate time
i did it with integer but with time i cant do it
this is the code
int TotalQuantity = 0;
protected void GridView1_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
TotalQuantity += Convert.ToInt32(DataBinder.Eval(e.Row.DataItem, "Quantity"));
}
else if (e.Row.RowType == DataControlRowType.Footer)
{
e.Row.Cells[0].Text = "TotalQuantity";
e.Row.Cells[0].Font.Bold = true;
e.Row.Cells[1].Text = TotalQuantity.ToString();
e.Row.Cells[1].Font.Bold = true;
}
}
