Ilogic- run program 2 times

Ilogic- run program 2 times

Anonymous
Not applicable
619 Views
4 Replies
Message 1 of 5

Ilogic- run program 2 times

Anonymous
Not applicable

I'm having an issue where when I run my RULES the model updates 99% of the assembly components.  The 1% will update if I run the RULE again with the same inputs.  What am I missing?

0 Likes
620 Views
4 Replies
Replies (4)
Message 2 of 5

adam.nagy
Autodesk Support
Autodesk Support

Hi there,

 

Sounds like there may be some interdependency between the operations you are doing, so some of them do not succeed for the first time around, but when certain things got updated, then the remaining 1% can get updated too?

 

Not sure if it makes sense in your case. Does it only happen to a certain assembly?
If you do similar update through the user interface, then all is fine?

 

Cheers, 



Adam Nagy
Autodesk Platform Services
0 Likes
Message 3 of 5

Anonymous
Not applicable

If I remember correctly I run into this sometimes when I am calculating a parameter in a rule and that parameter is used in a later rule. The later rule still uses the old parameter value therefore the parts doesn't update properly. To correct this I have to use RuleParametersOutput() and InventorVb.DocumentUpdate() at the end of the first rule. This way the later rule is using the new value. Not sure if this is what's happening in your case but just wanted to throw that out there.

Dan

0 Likes
Message 4 of 5

xiaodong_liang
Autodesk Support
Autodesk Support

Hi danvang,

 

Could you try to isolate to provide a test demo? It is hard to diagnose with the description only. Thank you.

0 Likes
Message 5 of 5

Anonymous
Not applicable

Here are two examples that I quickly came up with. I found different ways to make the code work but when you are initially writing it, you are expecting it to work a certain way and it doesn't. Hope these examples help.

 

Dan

0 Likes