📄 vba15-2.txt
字号:
Public Sub OpenOverviewWindow()
' Create the overview window.
Dim pDataWindowFactory As IDataWindowFactory
Dim pOverviewWindow As IOverviewWindow
Set pDataWindowFactory = New OverviewWindowFactory
If Not pDataWindowFactory.CanCreate(Application) Then
MsgBox "Unable to create overview window."
Exit Sub
End If
Set pOverviewWindow = pDataWindowFactory. _
Create(Application)
pOverviewWindow.Show True
' Set the layer displayed in the window.
Dim pMxDocument As IMxDocument
Dim pMap As IMap
Dim pLayer As ILayer
Dim pOverview As IOverview
Set pMxDocument = Application.Document
Set pMap = pMxDocument.FocusMap
Set pLayer = pMap.Layer(0)
Set pOverview = pOverviewWindow.Overview
pOverview.OverlayGridLayer = pLayer
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -