A
Al Edlund
well you can do it with a DoCmd something like this
Private Sub PanZoomToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles PanZoomToolStripMenuItem.Click
Dim vsoWindow As visio.Window
Dim vsoApplication As visio.Application
vsoWindow = AxDrawingControl1.Window
vsoApplication = vsoWindow.Application
vsoApplication.DoCmd(visCmdPanZoom)
End Sub
or you can use somethink like this (visio windows types are enumerated in
the documentation)
Private Sub setVisioExtraWindowVisibility( _
ByVal targetWindow As Microsoft.Office.Interop.Visio.Window, _
ByVal visVWT As Microsoft.Office.Interop.Visio.VisWinTypes, _
ByVal visible As Boolean)
Dim searchWindow As Microsoft.Office.Interop.Visio.Window
Try
' for identified window set the visibility attribute
searchWindow = targetWindow.Windows.ItemFromID(visVWT)
If (Not searchWindow Is Nothing) Then
searchWindow.Visible = visible
End If
Catch err As Exception
System.Diagnostics.Debug.WriteLine(err.Message)
End Try
End Sub
al
Private Sub PanZoomToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles PanZoomToolStripMenuItem.Click
Dim vsoWindow As visio.Window
Dim vsoApplication As visio.Application
vsoWindow = AxDrawingControl1.Window
vsoApplication = vsoWindow.Application
vsoApplication.DoCmd(visCmdPanZoom)
End Sub
or you can use somethink like this (visio windows types are enumerated in
the documentation)
Private Sub setVisioExtraWindowVisibility( _
ByVal targetWindow As Microsoft.Office.Interop.Visio.Window, _
ByVal visVWT As Microsoft.Office.Interop.Visio.VisWinTypes, _
ByVal visible As Boolean)
Dim searchWindow As Microsoft.Office.Interop.Visio.Window
Try
' for identified window set the visibility attribute
searchWindow = targetWindow.Windows.ItemFromID(visVWT)
If (Not searchWindow Is Nothing) Then
searchWindow.Visible = visible
End If
Catch err As Exception
System.Diagnostics.Debug.WriteLine(err.Message)
End Try
End Sub
al