This project has moved. For the latest updates, please go here.

Importing from xlsx doesnt import all rows

Jun 16, 2010 at 10:18 AM

Hi - Im experiencing trouble when importing cells from an excel 2007 file to a datatable.

Prosedure: The xlsx file is generated with Epplus, some cells are edited in excel2007, file is saved in excel 2007, file is imported via Epplus to datatable.

When NOT editing the cells in Excel, the import reads whole worksheet.

When editing some of the cells the import stops at random, on one of the edited rows.

So my question is: do anybody experience the same problems?

The code seems allright because all rows are imported when the xlsx file is not edited. So my guess is that the problems occurs because of user activity when editing the xlsx file. Corrupting the cells content with hidden characters like Tab/Enter etc...? I have tried to trim and remove tabs and linefeeds but nothing helps.

Im I missing something out?

Coordinator
Jun 16, 2010 at 10:25 AM

When you say stops, do you get an Exception?

Jun 16, 2010 at 10:57 AM

no...  the function proseeds with no error messages...

Coordinator
Jun 16, 2010 at 11:51 AM

ok..hard to tell what the problem is. Post your code here so I can have look.

Jun 16, 2010 at 4:18 PM

have found the problem - and Yes Im missing something out - my own code was the cause ;)

Svein