Access only not hidden rows

  • Thread starter Thread starter Volker Jobst
  • Start date Start date
V

Volker Jobst

Hi,

How can I go through my sheet by using offset(1,0) and selecting only
rows which are not hidden by the autofilter?

thanx volker jobst
 
Why would you want to?

dim rng as Range, rng1 as Range
set rng = Activesheet.Autofilter.Range
set rng = rng.offset(1,0).Resize(rng.rows.count-1)
On Error Resume Next
set rng1 = rng.SpecialCells(xlvisible)
rng1.Select
' or
'rng1.EntireRow.Select
 
I'm trying to do so because I want to count the values after the
autofilter has been set. I'll try your solution, thanx
 
Volker

Check out the SUBTOTAL Function for counting filtered rows.

Gord Dibben Excel MVP XL2002
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top