I need to count the total number of rows that have data. I want to be able to use this on multiple sheets with different amounts of data rows.
I cannot figure out gener
I found this method on http://www.mrexcel.com/
This computes the number of non-blank cells in column A of worksheet named "Data"
With Worksheets("Data")
Ndt =Application.Range("A:A").Cells.SpecialCells(xlCellTypeConstants).Count
debug.print Ndt
End With
The result is printed to the immediate window. You need to subtract 1 (or more) if column A has a header line (or lines) you do not wish to count.