Function to retrieve the Element object of a child in the specified Element object. For example,
this.parent specifies the parent layer of the script module as the Element object to be searched in. This function does not search in subelements. A particular child can be searched by name or position. The position is the number indexing the children in the specified Element object. If several children share the same name, only the first match will be returned. If no argument is set, the function returns the first child it finds.
Available in: Controller, Processor.
|nameOrPosition||The name or position of the child. Set this to |
nil to deactivate the search filter.
|string or number, optional|
Returns the Element object of the found child. Returns
nil if no child is found.
-- locate the first child in the program and print its name
child = this.program:getChild()
if child then
print("Could not find a child!")