We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

UtilityMethods.ConvertNumberToDateTime

Hi. I have some problems, when i try read excel file. Excel file contains date time column with values like this
 { 
25 Mar 2013, 
24 Mar 2013,
2403/2013
 }
last value is wrong as you see.
I use the next code:
{
         DataTable table = sheet.ExportDataTable(0, 0, 3, 1, ExcelExportDataTableOptions.DetectColumnTypes);
}
After this code line I have argument exception. In stack trace i have this line "Syncfusion.XlsIO.Implementation.UtilityMethods.ConvertNumberToDateTime(Double dNumber)". 
This seems like when DataTable fill  2403/2013 this value have wrong format maybe Out of DateTime values.
How i can take row and column where i have this exception?

1 Reply

SR Sudha Ramachandran Syncfusion Team January 27, 2015 05:20 PM UTC

Hi Vlad,

 

Thank you for using Syncfusion products.

 

Kindly try  using ‘ExportDataTable’ as represented in the below code snippet. If the issue still persists,  Please log on to our support website  and create a create a new direct-Trac incident for the same. It would be grateful for us to investigate further on this if you could share us the input template or issue reproducing sample.

 

Code Snippet:

 

DataTable table = sheet.ExportDataTable(1, 3, 4, 1, ExcelExportDataTableOptions.DetectColumnTypes);

 

 

Direct-Trac Link:  https://www.syncfusion.com/account/login?ReturnUrl=%2fsupport%2fdirecttrac%2fincidents

 

Please let us know if you have any queries.

Thanks,

Sudha R

Loader.
Live Chat Icon For mobile
Up arrow icon