Can i make the excel sheet zoom in /out so it always shows range A1 to T35?

tonywatsonhelp

Well-known Member
Joined
Feb 24, 2014
Messages
3,210
Office Version
  1. 365
  2. 2019
  3. 2016
Platform
  1. Windows
Hi Everyone,
I'd like a macro that can make the activesheet zoom in or out on any screen to show the range A1 to T35, now I realise that some screens might be able to show 50rows if its shows coulmns A to T, thats fine so I suppose we get it to zoom to alway show columns A to T then check if row 35 is visable, if not zoom so it is?
hope that makes sense and please help if you can as i'm stuck?

Thanks
Tony
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
You can play with something like below, how you fire the code would depend on your needs. The gist of it is to select the range and then use ActiveWindow.Zoom:

VBA Code:
Private Sub Worksheet_Activate()
    Range("A1:T35").Select
    ActiveWindow.Zoom = True
End Sub
 
Upvote 0
Solution
Thank you, i'll have a play and see what results i get looks like it should be what i need
Thanks
Tony
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,287
Members
452,631
Latest member
a_potato

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