A Long type property. ID of the layer (the ID property), on which the shape/service object is located.
Applies to: ServObj object, Shape object
[[Let] layerIDRet =] object.Layer [Let] object.Layer = layerIDSet |
The Layer property syntax has these parts:
Part | Description |
object | Required. An expression that returns an object in the Applies to list. |
layerIDRet | Optional. A Long type variable. |
layerIDSet | Required. An expression that returns a Long value. The ID of the layer. |
If there is no layer with the specified layerIDSet in the layer collection of the document, the Layer property doesn't change its value, as a shape can't be located on a nonexisting layer. To check whether the layer with the specified ID exists in the document, use the LayerByID method.
See Also |
ID property, LayerByID method, Layer object |