macro to set zoom properties of each tab

route217
route217 used Ask the Experts™
on
Hi Experts using excel 2010

Need a macro to set the zoom into worksheet tab properties of each to to as follows
1. Sheet 1 = 80%
2.sheet 2 = 110%
3 sheet 3 = 70%
4. Sheet 4 = 50%
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Top Expert 2014
Commented:
worksheets("Sheet1").activate
windows(1).Zoom = 80
worksheets("Sheet2").activate
windows(1).Zoom = 110
worksheets("Sheet3").activate
windows(1).Zoom = 70
worksheets("Sheet4").activate
windows(1).Zoom = 50

Open in new window

Older than dirt
Most Valuable Expert 2017
Distinguished Expert 2018
Commented:
You should probably add Application.ScreenUpdating = False before that code and Application.ScreenUpdating = True after it.
route217Junior

Author

Commented:
Hi Experts...I added this.code to the module..Thisworkbook and not working...
Top Expert 2014

Commented:
1. is your workbook macro enabled? (file extension = XLSM)
2. Did you place the code inside a SUB...END SUB structure?
3. How are you invoking the code?

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial