AnsweredAssumed Answered

Get seed component name of given pattern instance component

Question asked by Jana Stahn on Mar 28, 2017
Latest reply on Apr 4, 2017 by Jana Stahn

I have a component pattern (e.g. a linear pattern, circular pattern...).

I have one of the pattern instances as a Component2 object.


I am looking for a way to get the seed component name via the API.




The only way I can think of is to traverse the feature tree, collect all patterns and check if the given component (part1<3> in this case) is a member of any of these patterns. If yes, I can get the pattern data (e.g. for a linear pattern it is a LocalLinearPatternFeatureData object, for a circular pattern it is a LocalCircularPatternFeatureData object, and so on) and from there I can probably get the seed component somehow. When I have the component, I finally call Component2.Name2.


But there must be an easier way! Or not?