How can i Run a Rule in assembly for a other document?

How can i Run a Rule in assembly for a other document?

FeelGoodGirl
Advocate Advocate
583 Views
4 Replies
Message 1 of 5

How can i Run a Rule in assembly for a other document?

FeelGoodGirl
Advocate
Advocate

Hi,

I have a composition with different parts. I am looking for a piece of code with which I can run a rule in one of the parts. In the image below I have drawn what I mean.

example.png

So I am looking for a piece of code to put in the assembly, to run the rule in block 1.

 

After some searching work I found the piece of code below. But I can't get this to work.

iLogicAuto.RunRule(oDoc, "RuleName")
0 Likes
Accepted solutions (1)
584 Views
4 Replies
Replies (4)
Message 2 of 5

blandb
Mentor
Mentor

In the snippets, go to Run Other > Run Rule:

 

iLogicVb.RunRule("ruleName")

Is this what you are looking for? 

Autodesk Certified Professional
Message 3 of 5

mcgyvr
Consultant
Consultant
Accepted solution

Slightly more specific

iLogicVb.RunRule("block 1:1","Rule_Name")


-------------------------------------------------------------------------------------------
Inventor 2023 - Dell Precision 5570

Did you find this reply helpful ? If so please use the Accept Solution button below.
Maybe buy me a beer through Venmo @mcgyvr1269
Message 4 of 5

blandb
Mentor
Mentor

Oops, yes...copied wrong line...sorry 🙂

Autodesk Certified Professional
Message 5 of 5

FeelGoodGirl
Advocate
Advocate

SUPER, this was exactly what I meant! 😄

 

I did not realize that I could use the name in the assembly. Had already tried with the path of the file, but without success.