The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
I use ExcelRW to read and excel file and convert it to a DataTable. Can you help me with the following questions?
1. I used ExportDataTable to convert from IWorksheet to DataTable. However, the generated DataTable contained the formulas from the excel file. How can I get everything exported as numbers?
2. Is there a way to determine the last used row and column in the excel file?
Thanks,
Kjetil
ADAdministrator Syncfusion Team May 3, 2005 04:32 PM UTC
Hi Kjetil,
1) This is a shortcoming of the ExportDataTable method. I have filed a request to add an option to export the computed value
http://www.syncfusion.com/support/issues/excelrw/Default.aspx?ToDo=view&questId=287
Currently, you could get the computed value by using IRange.FormulaNumberValue
mySheet.Range["A1"].FormulaNumberValue
2) The last used row and column can be got using the IWorksheet.UsedRange
example,
mySheet.UsedRange.End.Column
Thanks,
Stephen.
>I use ExcelRW to read and excel file and convert it to a DataTable. Can you help me with the following questions?
>
>1. I used ExportDataTable to convert from IWorksheet to DataTable. However, the generated DataTable contained the formulas from the excel file. How can I get everything exported as numbers?
>
>2. Is there a way to determine the last used row and column in the excel file?
>
>Thanks,
>Kjetil