Inventor General Discussion

Inventor General Discussion

Reply
Active Contributor
-ianf-
Posts: 28
Registered: ‎01-07-2010
Message 1 of 10 (473 Views)

Run Sub-assembly rule from parent assembly

473 Views, 9 Replies
10-03-2012 04:33 AM

Is there a way to run a rule which is part of a sub assembly from the parent assembly?

 

I have a parent skeleton assembly containing many icopy assemblies. These subassemblies are based of one master assembly which in turn has a common part. (hence why I am using the icopy feature)

This standard part has an ilogic rule which varries the number of creases in a wall panel. eg. when the panel is 1200 wide there are 2 creases, when the panel is under 800 wide there is one crease and when the panel is less than 600 wide then there are no creases.

 

When I insert the icopy assembly into the master skeleton assembly and click select the widths of the panels they stretch and change to suit my skeleton. However I am having to visit each copied panel to run the crease rule.

 

Is there an operation or some sort of trigger I can implement to make this rule run as soon as the sub assembly is inserted?

 

Thanks.

 

Ian Farmery
Inventor 2010 Pro SP4, Vault Collaboration 2010
HP Z820 Xeon E5-2643 0 @ 3.3Ghz 16.0GB RAM
Nvidia Quadro 5000
*Expert Elite*
mrattray
Posts: 2,501
Registered: ‎09-13-2011
Message 2 of 10 (469 Views)

Re: Run Sub-assembly rule from parent assembly

10-03-2012 05:47 AM in reply to: -ianf-

There is a run rule in component snippet that you could use to create a rule that could loop through your component tree and run them. A better solution might be to play around with the iLogic triggers in the sub assembly document, try on open document.

Mike (not Matt) Rattray

Active Contributor
-ianf-
Posts: 28
Registered: ‎01-07-2010
Message 3 of 10 (447 Views)

Re: Run Sub-assembly rule from parent assembly

10-03-2012 11:15 PM in reply to: mrattray

Thank you Mike,

Tried looking at the triggers but nothing quite fits in with what I'm wanting to acheive.  How do I go about trying the run rule in component snippet?

Ian Farmery
Inventor 2010 Pro SP4, Vault Collaboration 2010
HP Z820 Xeon E5-2643 0 @ 3.3Ghz 16.0GB RAM
Nvidia Quadro 5000
Active Contributor
-ianf-
Posts: 28
Registered: ‎01-07-2010
Message 4 of 10 (444 Views)

Re: Run Sub-assembly rule from parent assembly

10-03-2012 11:36 PM in reply to: mrattray

Right,

 

Got a little but further.

Using the "run rule in component does work", however I now need a way of linking the generated icopy assembly names into the "partA:1" within the rule. 

Ian Farmery
Inventor 2010 Pro SP4, Vault Collaboration 2010
HP Z820 Xeon E5-2643 0 @ 3.3Ghz 16.0GB RAM
Nvidia Quadro 5000
*Expert Elite*
mrattray
Posts: 2,501
Registered: ‎09-13-2011
Message 5 of 10 (430 Views)

Re: Run Sub-assembly rule from parent assembly

10-04-2012 05:30 AM in reply to: -ianf-

Is it possible for you to post any of your files? I don't use iCopy, so I'll have to play around with your assembly to get some code that will loop through reliably.

Mike (not Matt) Rattray

Active Contributor
-ianf-
Posts: 28
Registered: ‎01-07-2010
Message 6 of 10 (423 Views)

Re: Run Sub-assembly rule from parent assembly

10-04-2012 06:52 AM in reply to: mrattray

I've attached 5 files.

1. Open Wall Assy.

2. Use iCopy and insert the Standard Wall Panel Assy.

3. Pick relevant points on skeleton.

4. Accept generated file names

 

In browser you should now have (under the icopy part) Standard Wall Panel Assy with skelton panel1:[x] & Standard Adaptive Panel1:[x]

 

The Creases Rule somehow needs populating with a captured part name. I don't want to have to keep visiting the rule and adding in the new part names.  Maybe I need to create some form of external rule referencing the Standard Adaptive Panel?

 

Many Thanks 

 

Ian Farmery
Inventor 2010 Pro SP4, Vault Collaboration 2010
HP Z820 Xeon E5-2643 0 @ 3.3Ghz 16.0GB RAM
Nvidia Quadro 5000
*Expert Elite*
mrattray
Posts: 2,501
Registered: ‎09-13-2011
Message 7 of 10 (417 Views)

Re: Run Sub-assembly rule from parent assembly

10-04-2012 08:21 AM in reply to: -ianf-

If you set the creases rule to trigger on "before save", the rule fires when the top level assembly (and it's iCopy sub assemblies) gets saved. Does this work for you?

Mike (not Matt) Rattray

Active Contributor
-ianf-
Posts: 28
Registered: ‎01-07-2010
Message 8 of 10 (408 Views)

Re: Run Sub-assembly rule from parent assembly

10-04-2012 11:06 PM in reply to: mrattray

Thanks Matt,

That does work.

Is there not a way you can get the rule to trigger using udpate within the assembly or create a rule another rule within the assembly to trigger the crease rule?

Ian Farmery
Inventor 2010 Pro SP4, Vault Collaboration 2010
HP Z820 Xeon E5-2643 0 @ 3.3Ghz 16.0GB RAM
Nvidia Quadro 5000
*Expert Elite*
mrattray
Posts: 2,501
Registered: ‎09-13-2011
Message 9 of 10 (399 Views)

Re: Run Sub-assembly rule from parent assembly

10-05-2012 04:17 AM in reply to: -ianf-

Rules are normally triggered when a parameter used in the rule is changed. If ther'es a parameter that will always change when the iCopy is placed then you could add that parameter in a redundant way to the rule.

Otherwise you'll have to use code at the assembly level, something like a loop that runs through each occurence in the assembly and looks for the parts to programmatically trigger the rules.

I think that the before save trigger is a good way to handle the problem, but if you want it to be triggered via code from the assembly for some reason (or just want an example of how it could be done) I can throw something together for you.

 

Mike (not Matt) Rattray

Active Contributor
-ianf-
Posts: 28
Registered: ‎01-07-2010
Message 10 of 10 (340 Views)

Re: Run Sub-assembly rule from parent assembly

11-01-2012 02:42 AM in reply to: mrattray

Thanks,

I will look into a parameter that will always change when the icopy is inserted and base a rule off that.

 

Ian Farmery
Inventor 2010 Pro SP4, Vault Collaboration 2010
HP Z820 Xeon E5-2643 0 @ 3.3Ghz 16.0GB RAM
Nvidia Quadro 5000
Announcements
Are you familiar with the Autodesk Expert Elites? The Expert Elite program is made up of customers that help other customers by sharing knowledge and exemplifying an engaging style of collaboration. To learn more, please visit our Expert Elite website.
Need installation help?

Start with some of our most frequented solutions or visit the Installation and Licensing Forum to get help installing your software.