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.
Unfortunately, activation email could not send to your email. Please try again.

DateTime FormatException

Thread ID:

Created:

Updated:

Platform:

Replies:

127946 Dec 20,2016 05:29 PM Dec 22,2016 04:18 AM Xamarin.Android 3
loading
Tags: XlsIO
Martin Dusek
Asked On December 20, 2016 05:29 PM

Hi,
this code produces "System.FormatException: Input string was not in a correct format." exception when last line of the code is reached.

            ExcelEngine excelEngine = new ExcelEngine();
            IApplication application = excelEngine.Excel;
            application.DefaultVersion = ExcelVersion.Excel2013;
            IWorkbook workbook = application.Workbooks.Create(1);
            IWorksheet worksheet = workbook.Worksheets[0];
            worksheet.Range[1, 1].DateTime = new DateTime(2016, 12, 20, 23, 25, 20);
            System.IO.MemoryStream stream = new System.IO.MemoryStream();
            workbook.SaveAs(stream);

Why and how to fix it?

Sridhar Sukumar [Syncfusion]
Replied On December 21, 2016 08:04 AM

Hi Martin, 
 
Thank you for contacting Syncfusion support. 
 

We are unable to reproduce the issue from our side. We suspect that this issue might be raised based on the machine culture. So, kindly share us the details about your machine culture which will be helpful for us to investigate further on this. 

  

Regards, 
Sridhar S. 


Martin Dusek
Replied On December 21, 2016 06:32 PM

Hi Sridhar,
my tablet is in Czech language.

Best regards

Martin

Sridhar Sukumar [Syncfusion]
Replied On December 22, 2016 04:18 AM

Hi Martin, 
 

We were able to reproduce the issue and have logged defect report regarding this. A support incident to track the status of this defect has been created under your account. Please log on to our support website to check for further updates 

  

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

  

Please let me know if you have any questions. 

 

Regards, 
Sridhar S. 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;