ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   autofilter range count (https://www.excelbanter.com/excel-programming/293441-autofilter-range-count.html)

pauluk[_14_]

autofilter range count
 
When you filter a range between to dates, does anyone know how to coun
the filtered results?

Regards
Pau

--
Message posted from http://www.ExcelForum.com


Frank Kabel

autofilter range count
 
Hi
have a look at
http://www.contextures.com/xlautofilter03.html#Count

--
Regards
Frank Kabel
Frankfurt, Germany

When you filter a range between to dates, does anyone know how to
count the filtered results?

Regards
Paul


---
Message posted from http://www.ExcelForum.com/


Tom Ogilvy

autofilter range count
 
Actually that would be more robust if it were

Sub CountVisRows()
'by Tom Ogilvy
Dim rng As Range
Set rng = ActiveSheet.AutoFilter.Range

MsgBox rng.Columns(1). _
SpecialCells(xlVisible).Count - 1 _
& " of " & rng _
.Rows.Count - 1 & " Records"

End Sub
-- Regards,Tom Ogilvy"Frank Kabel" wrote in message
...
Hi
have a look at
http://www.contextures.com/xlautofilter03.html#Count

--
Regards
Frank Kabel
Frankfurt, Germany

When you filter a range between to dates, does anyone know how to
count the filtered results?

Regards
Paul


---
Message posted from http://www.ExcelForum.com/




Debra Dalgleish

autofilter range count
 
Thanks Tom. I've updated the code.

Tom Ogilvy wrote:
Actually that would be more robust if it were

Sub CountVisRows()
'by Tom Ogilvy
Dim rng As Range
Set rng = ActiveSheet.AutoFilter.Range

MsgBox rng.Columns(1). _
SpecialCells(xlVisible).Count - 1 _
& " of " & rng _
.Rows.Count - 1 & " Records"

End Sub
-- Regards,Tom Ogilvy"Frank Kabel" wrote in message
...

Hi
have a look at
http://www.contextures.com/xlautofilter03.html#Count

--
Regards
Frank Kabel
Frankfurt, Germany


When you filter a range between to dates, does anyone know how to
count the filtered results?

Regards
Paul



--
Debra Dalgleish
Excel FAQ, Tips & Book List
http://www.contextures.com/tiptech.html



All times are GMT +1. The time now is 01:44 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com