Spire.XLS is a professional Excel .NET library that can be used to any type of .NET( C#, VB.NET, ASP.NET, .NET Core) application and Java (J2SE and J2EE) application.

Thu Apr 10, 2008 12:09 pm

when I try to load a DataTable containing some DateTime columns the method InsertDataTable throws an exception with this message: "System.InvalidCastException: Unable to cast object of type 'n2' to type 'Spire.Xls.CellRange'."
I have the same error after casting DateTime to String.

Another question:
How I can format an Excel column in datetime format?

Thanks very much


Posts: 2
Joined: Thu Apr 10, 2008 11:05 am

Wed Apr 16, 2008 2:50 am

Thank you for reporting bug to us.
We will fix the bug in next release.
User avatar

Posts: 56
Joined: Thu Jun 29, 2006 2:34 pm

Return to Spire.XLS