Macro to activate macros on other sheets

awesomebox8

New Member
Joined
Nov 11, 2016
Messages
3
I have an excel model that is used for real estate acquisitions. 8 of the 13 sheets contain a simple macro (activated by two separate buttons) to hide or reveal blank cells. I would like to create a macro on the Summary sheet to activate the "Hide" button on each of the 8 sheets.

Is there a simple way to do this? I have one that works to reveal all of the hidden rows and columns see below, but cannot figure out how to activate the hide macros. Thank you for your help!

Sub UnhideAll()
Dim ws As Worksheet
Dim starting_ws As Worksheet
Set starting_ws = ActiveSheet
For Each ws In ThisWorkbook.Worksheets
ws.Activate
Columns.EntireColumn.Hidden = False
Rows.EntireRow.Hidden = False
Next
starting_ws.Activate
End Sub
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
Where are the 'hide' macros located?
 
Upvote 0
Are the hide macros the same for each sheet?
 
Upvote 0
They are not the same for each sheet. The ranges will vary depending on which cell values I am looking at hiding.
 
Upvote 0

Forum statistics

Threads
1,214,424
Messages
6,119,404
Members
448,893
Latest member
AtariBaby

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