Hi Jiwon,
Thanks for using Syncfusion products.
On analysis we found that XlsIO takes 20 min (nearly) to read the cell of the sheet which contains values in 25000 rows and 30 columns as ’sheet.Rows.Length’, 'sheet.Columns.Length' properties are called on each loop execution. So please as workaround, assign the 'sheet.Rows.Length' and 'sheet.Column.Length' to local variable and use that local variable in for loop. When using this workaround, we could see that XlsIO takes 3 seconds to read the cell values.
Code snippet:
foreach (IWorksheet sheet in workbook.Worksheets)
{
int rowLength = sheet.Rows.Length;
int columnLength = sheet.Columns.Length;
for (int row = 1; row <= rowLength; row++)
{
for (int column = 1; column <= columnLength ; column++)
{
object cell = sheet.GetValueRowCol(row, column);
//Do something
}
}
}
We have attached the simplified sample with the above scenario. Please make use of this and let us know whether this helps you.
Thanks,
Manikandan.M
Performance_2185a604.zip