long MaxCol = 0;
long MaxRow = 0;
foreach (var worksheet in Workbook.Worksheets(@"T:\Libro1.xlsx"))
MaxCol = worksheet.MaxColumnIndex;
foreach (var row in worksheet.Rows)
foreach (var cell in row.Cells)
if (cell != null)
MessageBox.Show("Column: " + cell.ColumnIndex + "\nContent: " + cell.Text);
Quote:My problem is I can retrieve the column number with cell.ColumnIndex and cell content with cell.Text, but I don't know how to get the row number of the cell, So I can't extract the data successfully.
Quote:There is no RowIndex in Cell, there is only ColumnIndex.
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)