Hi All,
I am looking for a VBA code that sets a Visio Viewer Zoom to a page.
There is a property .Zoom but this takes a double value. How can i set tit to a page view..?
Any idea..
Try the Default 0.6 or the special -1 to adjust window to pagesize.
Try this snipt, it changes all sheets to 'Fit in Page'.
Public Sub FitToPageAll()
Dim PageToIndex As Visio.Page
Dim curPage As Visio.Page
Set curPage = ActivePage
' loop through all the pages you have and set the zoom factor
For Each PageToIndex In ActiveDocument.Pages
ActiveWindow.Page = ActiveDocument.Pages(PageToIndex.Index).Name
ActiveWindow.Zoom = -1
Next
ActiveWindow.Page = curPage
End Sub