Article ID: 148621
Article Last Modified on 10/11/2006
Sub Count_Filtered_Rows()
Dim UpperLeftCorner As Range
' UpperLeftCorner should be set to the upper-left
' corner of the list range:
Set UpperLeftCorner = Sheets("Sheet1").Range("A1")
rowcount = -1
For Each area In _
UpperLeftCorner.CurrentRegion.SpecialCells(xlVisible).Areas
rowcount = rowcount + area.Rows.Count
Next
MsgBox rowcount
End Sub
Additional query words: 5.00a 5.00c 8.00 XL98 XL97 XL7 XL5 XL
Keywords: kbdtacode kbhowto kbprogramming KB148621