Hi there,
I'm trying to output into the gridview row (15) the date in dd/mm/yy or any other readable format.
I keep getting an exception.
Whta can I cahnge in the following code to fix this issue?
Many thanks.
I have to following code:
Code:protected void gvReport_RowDataBound(object sender, GridViewRowEventArgs e) { if (e.Row.RowType == DataControlRowType.DataRow) { Int64 iEntryDate = Convert.ToInt64((string)e.Row.Cells[15].Text); System.DateTime dt = new System.DateTime(1970, 1, 1); dt = dt.AddSeconds(iEntryDate); string s = dt.ToLongDateString(); e.Row.Cells[15].Text = s; } }


Reply With Quote

Bookmarks