GetChildNames [Modeler]

Returns the names of children for a specified input. For 3D Components and UDMs, these commands do not return parts, coordinate systems, plans, as top-level modeler children.

Note:

This command is not supported by the EMIT and Circuit design types.

UI Access N/A
Parameters
Name Type Description
<category> String

Optional. Passing no input returns the list of possible strings:

  • "AllParts" – Returns the names of all parts.
  • "CoordinateSystems" – Returns the names of all coordinate systems.
  • "Groups" – Returns the names of all groups.
  • "Lists" – Returns the names of all lists.
  • "ModelParts" – Returns names of model parts.
  • "NonModelParts" – Returns the names of non-model parts.
  • "Planes" – Returns the names of all planes.
  • "Points" – Returns the names of all points.
  • "SubmodelDefinitions" – Returns the names of submodel definitions.
Return Value Array containing object names in the selected category.

 

Python Syntax GetChildNames(<category>)
Python Example

Standalone Example:

oEditor.GetChildNames("ModelParts")

oEditor.GetChildNames("Points")

Example used in Conjunction with GetChildObject and GetPropNames:

oDesign = oProject.GetActiveDesign()

oModel = oDesign.GetChildObject("3D Modeler")

oModel.GetChildTypes()

  • This returns an array containing strings: "ModelParts", "AllParts", "NonModelParts", "CoordinateSystems", "Points", "Planes", "SubmodelDefinitions", "Groups", and "Lists".

oModel.GetChildNames("ModelParts")

  • This returns an array containing string model parts. For example: "WG_Interior", "WG", "MT_Interior", "MT", "Box2", "Cylinder1".

oWGi = oModel.GetChildObject("WG_Interior")

  • This sets the object WG_Interior to variable oWGi.

oWGi.GetPropNames()

  • This returns property names from child object assigned to oWGi. In this case: "Name", "Material", "Material/SIValue", "Material/EvaluatedValue", "Solve Inside", "Orientation", "Orientation/Choices", "Model", "Display Wireframe", "Material Appearance", "Color", "Color/Red", "Color/Green", "Color/Blue", and "Transparent".