AnsweredAssumed Answered

Get the suppression state of a sketch inside a part in an assembly in a view in a drawing

Question asked by Eric Snyder on Jun 8, 2020

I have:


  -> Sheet1

    -> Drawing View1

      -> Assembly1

        -> Part1<Default>

        -> Part1<Left>

          -> Sketch1

I need to get the suppression state of

Drawing->Sheet1->Drawing View1->Assembly1->Part1<Left>->Sketch1



Part1 has derived configurations:



    -> Left

    -> Right

It seems to get the suppression state you have to specify the configuration name using IFeature::IsSuppressed. I don't seem to be able to get the correct configuration name using model.GetActiveConfigurationName. I get "Default" instead of "Left".


Specifically, how do I get the suppression state of a feature inside a assembly/component?


How do I get the proper configuration name?


By the way...I have tried:

swLinkedToParent4 = Valid only for derived configurations; if specified for non-derived configurations, then the active configuration is used

IFeature::IsSuppressed2((int)swInConfigurationOpts_e.swLinkedToParent, new object[] { "Left"} );

If the feature is in a non derived configuration then it returns null.