IsLayerParentOf

Verifies that a layer is a parent of another layer.

Syntax

rhinoscriptsyntax.IsLayerParentOf (layer, test)

rhinoscript.layer.IsLayerParentOf (layer, test)

Parameters

layer

Required.  String or Guid.  The name or id of the layer to test against.

test

Required.  String or Guid.  The name or id of the layer to test

Returns

Boolean

True if test is a parent of layer. False otherwise.

Example

import rhinoscriptsyntax as rs

rs.AddLayer("MyLayer1")

rs.AddLayer("MyLayer2", parent="MyLayer1")

rs.AddLayer("MyLayer3", parent="MyLayer2")

rs.MessageBox( rs.IsLayerParentOf("MyLayer3", "MyLayer1") )

Also See

IsLayerChildOf