Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Previous Sheet

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,

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default Previous Sheet

If Activesheet.Index 1 then Activesheet.Previous.Activate

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"vandaley" wrote in message
oups.com...
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,



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Previous Sheet

Sorry mate but it still doesnt work.
i am stuck on the same sheet and it doesnt go back.

Any idea?

Bob Phillips wrote:
If Activesheet.Index 1 then Activesheet.Previous.Activate

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"vandaley" wrote in message
oups.com...
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,


  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default Previous Sheet

Post all your code.

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"vandaley" wrote in message
ups.com...
Sorry mate but it still doesnt work.
i am stuck on the same sheet and it doesnt go back.

Any idea?

Bob Phillips wrote:
If Activesheet.Index 1 then Activesheet.Previous.Activate

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"vandaley" wrote in message
oups.com...
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,




  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 225
Default Previous Sheet

Bob's code works for me. Are there any hidden
worksheets? If the previous sheet is hidden then
Activate (silently) fails.

Andrew

vandaley wrote:
Sorry mate but it still doesnt work.
i am stuck on the same sheet and it doesnt go back.

Any idea?

Bob Phillips wrote:
If Activesheet.Index 1 then Activesheet.Previous.Activate

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"vandaley" wrote in message
oups.com...
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,




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
transfer contents from a cell in previous sheet if the sheet is a DarkNight New Users to Excel 1 September 9th 08 01:04 AM
Copying the repeated data of the previous sheet to the next sheet Sasikiran Excel Discussion (Misc queries) 1 September 25th 07 03:18 PM
Add a Sheet From a Previous Sheet Macro Don Excel Worksheet Functions 3 November 10th 06 11:41 PM
new sheet with same name as previous. GeneWan Excel Programming 3 March 27th 06 09:36 AM
Refer new sheet to previous sheet Spot Excel Worksheet Functions 2 September 9th 05 02:05 PM


All times are GMT +1. The time now is 11:58 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"