AddLayer

The AddLayer method adds a new layer. Returns a Layer object.

 

Syntax

object.AddLayer( LayerName )

 

Parameter

Type

Description

LayerName

String

required; new layer name

 

Example

This example adds a new map layer named "New Layer" to the map window.

 

Dim mvApp As Object

Set mvApp = CreateObject("MapViewer.Application")

Set Plot = mvApp.Documents.Add(DocType:=mvDocPlot)

Set MapLayers = Plot.Layers

MapLayers.AddLayer("New Layer")

 

Used by: Layers collection