Search code examples
vbacatia

List of CATVBA InputObjectTypes?


For CATIA V5, the following lines of code prompt the user to select a feature, filtered by type.

Dim InputObjectType(0) As Variant
InputObjectType(0) = "Point"
selection1.SelectElement2(InputObjectType, "Select a point", true)

etc...

I want to filter on Geometrical Sets. "Geometrical Set", "GeometricalSet", and "GeoSet" do not work. Is there a list or table of object type names? The v5automation.chm file does not offer any clues.


Solution

  • Not sure if you're checking SO for answers or not - doesn't look like many others have been able to answer your questions to date

    If this works for you please mark it as an answer and gain points for yourself as well as myself - and helping future users

    I believe you can find a Geometrical set by searching for "HybridBody"

    Note: Both Geometric set and Repetition(Points and Planes) are HybridBody

    Change your lines of code to:

    InputObjectType(0) = "HybridBody"
    selection1.SelectElement2(InputObjectType, "Select a Geo Set", true)
    

    Found a list of types - not sure if it's full or not

    Other
    Volume
    Surface
    Cylinder
    Sphere
    Cone
    Plane
    Curve
    Circle
    Line
    Point
    Axis System