Export datatable with column type datetime to excel

Technical support for Spire.DataExport

Moderators: iceblue support, DataExport, Manager

Export datatable with column type datetime to excel

Postby stc@seapay.dk » Tue Apr 14, 2009 11:05 am

I am trying to export a datatable where i have multiple columns of datatype 'Datetime'

I have added code in the event

private void cellExport1_GetDataParams(object sender, Spire.DataExport.EventArgs.DataParamsEventArgs e)
if (e.Col == 3)
e.FormatText = "yyyy-mm-dd hh:mm:ss";


but when looking in the excel sheet the column is formatted as yyyy-mm-dd 00:00:00.

I know for a fact that the column contains a time different from 00:00:00.

Could you please help me with this formatting issue.

:? :? :?

Steen Christiansen
Seapay Aps
Posts: 4
Joined: Tue Aug 19, 2008 8:32 am

Return to Spire.DataExport

Who is online

Users browsing this forum: No registered users and 0 guests