Previous Sheet

  • Thread starter Thread starter vandaley
  • Start date Start date
V

vandaley

Hi,

I am using the next function ActiveSheet.Previous.Activate with a
button to move to the previous sheet.
The button is on every sheet and should always go back till the first
one.
All works fine until i get to a sheet that doesnt go back to the one
before.
If i move manually and then press the button i can skip that sheet.

Whats wrong?
any other way of doing that?

Thanks,
 
If Activesheet.Index > 1 then Activesheet.Previous.Activate

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
Sorry mate but it still doesnt work.
i am stuck on the same sheet and it doesnt go back.

Any idea?
 
Post all your code.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)
 
Bob's code works for me. Are there any hidden
worksheets? If the previous sheet is hidden then
Activate (silently) fails.

Andrew
 

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