I have to parse through and store the contents of each cell in an array.
I wrote the following. But when i print the contents of my resultant
array “contents” all i get is [nil,nil,nil…nil]. Please correct where
i am wrong?
In the following code i am first getting what is the max number of rows
and cols i have in the xlsx file. Then run through the cells using the
lastRow and lastColumn in the for loop.
#Excel file instance
workbook = Excelx.new(ARGV)
#Need to find the count of lastrow and last column
lastRow = workbook.last_row
lastColumn = workbook.last_column
print “Last row -”+" “, lastRow
print “Last column -”+” ",lastColumn
#parse the first sheet contents
contents = 
for i in 1…lastRow do
for j in 1…lastColumn do