ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Hidden Worksheet (https://www.excelbanter.com/excel-programming/385251-hidden-worksheet.html)

RJG

Hidden Worksheet
 
I have put a button on a summary worksheet to go to a 2nd worksheet
and this works fine. However i have now hidden the 2nd worksheet and
my simple code will nolonger find it.
Can I still use the button (but just amend the code) if the 2nd
worksheet is "hidden". Or do I have to unhide the sheet for it to
work.
This is the simple code that i am using, can it be changed

Private Sub CommandButton3_Click()
Sheets("BIC code summary").Select
End Sub



Bob

ps I also have another button on the hiden sheet to return to the
original sheet.


Mike

Hidden Worksheet
 
Change you macro to
Sheets("BIC code summary").Visible = True
Sheets("BIC code summary").Select

On the button to return if you want to hide it again then add
Sheets("BIC code summary").Visible = false

Mike


"RJG" wrote:

I have put a button on a summary worksheet to go to a 2nd worksheet
and this works fine. However i have now hidden the 2nd worksheet and
my simple code will nolonger find it.
Can I still use the button (but just amend the code) if the 2nd
worksheet is "hidden". Or do I have to unhide the sheet for it to
work.
This is the simple code that i am using, can it be changed

Private Sub CommandButton3_Click()
Sheets("BIC code summary").Select
End Sub



Bob

ps I also have another button on the hiden sheet to return to the
original sheet.



RJG

Hidden Worksheet
 
Mike,
Perfect, thank you

Bob


Mike wrote:
Change you macro to
Sheets("BIC code summary").Visible = True
Sheets("BIC code summary").Select

On the button to return if you want to hide it again then add
Sheets("BIC code summary").Visible = false

Mike


"RJG" wrote:

I have put a button on a summary worksheet to go to a 2nd worksheet
and this works fine. However i have now hidden the 2nd worksheet and
my simple code will nolonger find it.
Can I still use the button (but just amend the code) if the 2nd
worksheet is "hidden". Or do I have to unhide the sheet for it to
work.
This is the simple code that i am using, can it be changed

Private Sub CommandButton3_Click()
Sheets("BIC code summary").Select
End Sub



Bob

ps I also have another button on the hiden sheet to return to the
original sheet.





All times are GMT +1. The time now is 10:52 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com