Layer.Layers
 
 
 

Layer.Layers

Introduced

v10.0 (2012)

Description

Returns the layer children nodes of this layer node as a LayerCollection object.

C# Syntax

// get accessor
LayerCollection rtn = Layer.Layers;

Examples

VBScript Example

NewScene ,False
CreateLayer , "MyLayerExample"
'The command creates a Layer Group
CreateLayerGroup , "Layers.MyLayerExample", "MyLayerGroup"
set CurrentScene = Application.ActiveProject2.ActiveScene
Logmessage CurrentScene.Layers.Count
For each oLayer in CurrentScene.Layers
        Logmessage oLayer.fullname
Next
CurrentScene.Layers(1).AddLayer CurrentScene.Layers(0)
Logmessage CurrentScene.Layers.Count
For each oLayer in CurrentScene.Layers
        Logmessage oLayer.fullname
Next
Output from above script
' INFO : 2
' INFO : Layers.Layer_Default
' INFO : Layers.MyLayerGroup
' INFO : 1
' INFO : Layers.MyLayerGroup