Using Variable in Rows(x:y) function

  • Thread starter tedpeterborough
  • Start date
T

tedpeterborough

I have a particular problem I can't solve - I just want to know if wha
I want to do is possible. I want to be able to hide certain rows.
have a loop with a simple counter - once the loop is finished, I wan
to hide from row=count to 72.

I have tried using a constant, and it doesn't work either.
The macro works if I substitute count with a number.

Rows("count:72").Select
Selection.EntireRow.Hidden = Tru
 
B

Bob Phillips

Rows(count & ":72").EntireRow.Hidden = True


--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Top