Windows Collection

 

The Windows collection provides access to all windows within MapViewer. The Windows collection returned by the Application object contains all the windows in the application, including the map window and the worksheet window. The Windows collection returned by the PlotDocument object contains all the windows opened on the parent map document. The Windows collection returned by the WksDocument object contains all the windows opened on the parent worksheet document.

 

Properties

Application

Count

Parent

 

Methods

Arrange

Item*

 

*default method

 

Example

This example references the Windows collection for the MapViewer application.

 

Sub Main

'Declares mvApp as an object

 Dim mvApp As Object

 

'Creates an instance of the MapViewer Application

'object and assigns it to the variable named "mvApp"

 Set mvApp = CreateObject("MapViewer.Application")

 

'Makes MapViewer visible

 mvApp.Visible = True

 

'Declares Plot as an object

 Dim Plot As Object

 

'Creates a PlotDocument object in MapViewer

'and assigns it to the variable named "Plot"

 Set Plot = mvApp.Documents.Add(mvDocPlot)

 

'Declares Windows as an object

 Dim Windows As Object

 

'Assigns the Windows Collection to the

'variable named "Windows"

 Set Windows = mvApp.Windows

End Sub