Angelo Dundee
Board Regular
- Joined
- Nov 18, 2002
- Messages
- 167
The following macro, each time it is executed reduces the zoom
size of all the sheets by 10%, to a minimum of 50% :-
Dim myZoom As Integer
myZoom = ActiveWindow.Zoom - 10
If myZoom >= 50 Then
ActiveWindow.Zoom = myZoom
Dim currentSheet As Worksheet
Set currentSheet = ActiveSheet
Dim mySheet As Worksheet
For Each mySheet In Worksheets
mySheet.Activate
ActiveWindow.Zoom = myZoom
Next mySheet
currentSheet.Activate
End If
The problem with this macro is that I don't want to have to
make a sheet active in order to reduce it. ( because they
momentarily appear on the screen )
Can I reduce a sheet without making it active, if so what
code would I use to replace some of the above ?
size of all the sheets by 10%, to a minimum of 50% :-
Dim myZoom As Integer
myZoom = ActiveWindow.Zoom - 10
If myZoom >= 50 Then
ActiveWindow.Zoom = myZoom
Dim currentSheet As Worksheet
Set currentSheet = ActiveSheet
Dim mySheet As Worksheet
For Each mySheet In Worksheets
mySheet.Activate
ActiveWindow.Zoom = myZoom
Next mySheet
currentSheet.Activate
End If
The problem with this macro is that I don't want to have to
make a sheet active in order to reduce it. ( because they
momentarily appear on the screen )
Can I reduce a sheet without making it active, if so what
code would I use to replace some of the above ?