exceljs / exceljs

Excel Workbook Manager

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Getting a column/row count

ljkmchale opened this issue · comments

There needs to be a feature that allows you to get a column and row count.

Pretty Please :)

Added rowCount, actualRowCount, columnCount, actualColumnCount to Worksheet and cellCount and actualCellCount to Row in 0.2.35

Hi guyonroche,
I am building a framework using the protractor and i am using exceljs for reading data from xls file which contains multiple files.
i am facing issue in getting the row count and column count.

Can you please help me by providing an simple example to get the rowcount from an excel.
Below is the code i am using for reading the excel.

var xlsx = require('xlsjs');
var Excel = require('exceljs');
var workbook = new Excel.Workbook();
workbook.xlsx.readFile(filename).then(function() {
var worksheet = workbook.getWorksheet(SheetName);
worksheet.eachRow({ includeEmpty: true }, function(row, rowNumber) {
console.log("Row " + rowNumber + " = " + JSON.stringify(row.values));
});
Can you please help me in reading the excel and getting the row count and column count so that i can use it as per my requirement.

Thanks in Advance.

@AV090909
Any solution for reading number of rows/column from excejs?