Description
Sets or returns the layer that the entity is on.
Property type
Write-only property
Syntax
Visual Basic |
---|
Public Property Layer |
Remarks
If you don't specify a layer, the current active layer is used for a new entity. If a layer is specified for an entity, the current active layer is ignored. Each layer has associated properties that can be set and queried through the Layer object.
Example
Private Sub LayerpropertyExample()
'This example returns the Layer property.
Dim ents As Object
Dim ent As Object
Set ents = ActiveDocument.ModelSpace
Set ent = ents.Item(ents.Count - 1)
MsgBox "The Layer property for the last entity is: " & ent.Layer
End Sub