Import Spreadsheet reading row by row

1 Answer 78 Views
Spreadsheet
Bernie
Top achievements
Rank 1
Bernie asked on 23 May 2023, 02:22 PM

I need to import a spreadsheet into a dataset. The spreadsheets have rows and columns of data, but some of the columns are totaled at the bottom. I think this is giving me error when trying to use the DataTableFormatProvider.Export.

So I want to open the file and read the cells row by row. Are there any examples on how to open a spreadsheet and walk through it row by row?

1 Answer, 1 is accepted

Sort by
0
Yoan
Telerik team
answered on 26 May 2023, 10:49 AM

Hello, Bernie

I was able to reproduce the same results you are describing and have logged this behavior as an item in our Feedback Portal: SpreadProcessing: Exception "Invalid data passed" is thrown when exporting with DataTableProvider and a column containing а formula. If you'd like you can subscribe to the task in order to track its progress and get notified of any future updates.

I apologize if this is causing you any setbacks. I have updated your Telerik Points as a sign of appreciation for bringing this up.

As a workaround, I can suggest:

  • If you'd like to keep the totaled cells you can set their value manually and not have a formula in them.
  • If the totaled cells are not required in the final result you can delete them completely before exporting.

And if you are still interested, more information on iterating Spreadsheet cells and having access to their properties can be found in the following articles:

If you have any other questions or feedback you would like to share, feel free to do so.

Regards,
Yoan
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

Tags
Spreadsheet
Asked by
Bernie
Top achievements
Rank 1
Answers by
Yoan
Telerik team
Share this question
or