Thread: Count Cells
View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Count Cells

Another (works with a column where there may be missing values)

msgbox ActiveSheet.AutoFilter.Range.Columns(1) _
.SpecialCells(xlvisible).count-1

--
Regards,
Tom Ogilvy


Pedro wrote in message
...
Hi
If when I apply a Filter it gives me 5 records, or 7, or whatever number

of
records.
What code should I write in order to give me the number of records (rows)

,
5, 7 whatever

thanks
Pedro