How to reference feature in a subcomponent from assembly using ilogic

How to reference feature in a subcomponent from assembly using ilogic

SECOJOSE
Contributor Contributor
171 Views
2 Replies
Message 1 of 3

How to reference feature in a subcomponent from assembly using ilogic

SECOJOSE
Contributor
Contributor

The goal is to have features in a subcomponent match the state of the mating part in the assembly. For example, if you have an assembly that has a block with a hole that holds a rod. If you suppress the rod in the assembly, the hole will be suppressed in the block. I want to know if this can be accomplished by setting the "IsActive" state of the rod with the active state of the hole feature in the subcomponent. Specifically, I'm asking for the ilogic code that can reference subcomponent features in the assembly's ilogic. I currently have a Boolean parameter in the assembly that passes to the subcomponent but want to get away from that method.

0 Likes
Accepted solutions (1)
172 Views
2 Replies
Replies (2)
Message 2 of 3

A.Acheson
Mentor
Mentor

Hi @SECOJOSE 

Have you tried to manually to the changed and then iprn the ilogic editor and expand your browser and select the features to control and right click and use capture tool? 

If this solved a problem, please click (accept) as solution.‌‌‌‌
Or if this helped you, please, click (like)‌‌
Regards
Alan
0 Likes
Message 3 of 3

A.Acheson
Mentor
Mentor
Accepted solution

Hi @SECOJOSE 

 

Duplicate question here

Code assuming part is just inside the main assembly.

If Component.IsActive("Shaft") = False Then
	
	' ***Hole1***
	Feature.IsActive("Tube", "Hole1") = False

End If

 

AAcheson_0-1706033192859.png

 

 

If this solved a problem, please click (accept) as solution.‌‌‌‌
Or if this helped you, please, click (like)‌‌
Regards
Alan
0 Likes