G Guest Nov 3, 2005 #1 When using VBA to access the Autofilter method, is there a way to access the # of Records found?
T Tom Ogilvy Nov 3, 2005 #2 Not really (since there is no guarantee it will be in the status bar), but it is easy to get dim rng as Range set rng = Activesheet.autofilter.Range.columns(1).Cells set rng = rng.specialcells(xlvisible) msgbox "Records found: " & rng.count - 1 you subtract 1, because rng would include the header row.
Not really (since there is no guarantee it will be in the status bar), but it is easy to get dim rng as Range set rng = Activesheet.autofilter.Range.columns(1).Cells set rng = rng.specialcells(xlvisible) msgbox "Records found: " & rng.count - 1 you subtract 1, because rng would include the header row.
G Guest Nov 3, 2005 #3 THANK YOU. I knew there had to be a way to get the information I needed. I just needed to submit the question the right way. You guys are the best. Microsoft chose their MVP's very well
THANK YOU. I knew there had to be a way to get the information I needed. I just needed to submit the question the right way. You guys are the best. Microsoft chose their MVP's very well