I am doing Export to Excel process in my asp.net application.
In that process, I am writting the DateTime value to excel using the below code:
string reqDate = item.requestedDate.ToString("MM/dd/yyyy hh:mm:ss tt");
Response.Write(reqDate + "\t");
But the result in the excel file missing the second part in the datetime like below:
4/3/2014 17:05
I want it look like 04/03/2014 05:05:19 PM
How to do this?
Please help.