How can I toggle sheet tabs on/off using a Check Box?

VH5150

Board Regular
Joined
Mar 1, 2004
Messages
60
I am trying to toggle my sheet tabs on and off using a check box from the forms toolbar. How do I do this?
 

Excel Facts

Can a formula spear through sheets?
Use =SUM(January:December!E7) to sum E7 on all of the sheets from January through December
Try using one from the Control Toolbox, then you can use it's click event as follows-

Code:
Private Sub CheckBox1_Click()

ActiveWindow.DisplayWorkbookTabs = CheckBox1

End Sub

Change CheckBox1 to match the name of your checkbox if necessary.
 
Upvote 0
If you are set on the Forms toolbar for your checkbox, then right-click it, left click on Assign Macro, and assign it this one, which goes in a standard module:

Sub Test1()
With ActiveWindow
.DisplayWorkbookTabs = Not .DisplayWorkbookTabs
End With
End Sub
 
Upvote 0

Forum statistics

Threads
1,214,534
Messages
6,120,080
Members
448,943
Latest member
sharmarick

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top