This project is read-only.


Corrupt Spreadsheet with PasteDataTable with bit Fields


I have a dataset returning from a SQL database which contains a bit field. When this data table is pasted into an empty spreadsheet I get and error when opeing the file in Excel. The data appears correct when Excel fixes the problem. I have removed the fields returned one by one and have confirme that the bit field is the problem.
BTW - Good work and thanks.


EricGelders wrote Nov 3, 2009 at 7:39 AM

I can confirm the behaviour described above by beaunidle. Trying to achieve the same goal, I also noticed that trying to write boolean values from an SQL Server database into an Excel 2007 sheet (by inserting a DataTable object, using the InsertDataTable method) results in a corrupted xlsx file. Excel is able to fix the problem on opening the file, but I feel this is not a behaviour to be desired. The DataTable is filled by a SQL statement, no LINQ to SQL.

Simple OOXML is a good library to work with; much more intuitive than the OXML SDK. Good job!

JamesWestgate wrote Jan 26, 2010 at 8:50 PM

Bug confirmed. Unit test added WorksheetDataTablePasteTest.

wrote Jan 26, 2010 at 8:51 PM

JamesWestgate wrote Jan 26, 2010 at 9:48 PM

Fixed. Thank you for the feedback.

wrote Feb 22, 2013 at 12:11 AM

wrote May 16, 2013 at 11:43 AM

wrote May 16, 2013 at 11:43 AM

wrote Jun 14, 2013 at 8:25 AM