How to replace the part in assembly -ilogic

How to replace the part in assembly -ilogic

Anonymous
Not applicable
852 Views
1 Reply
Message 1 of 2

How to replace the part in assembly -ilogic

Anonymous
Not applicable

I am trying  use ilogic  to replace the part from different location in the assembly file. Any thought will help! Thank you! 

0 Likes
853 Views
1 Reply
Reply (1)
Message 2 of 2

WCrihfield
Mentor
Mentor

Are you familiar with the 2 methods defined under the ComponentOccurrence object for replacing the component?  They are Replace & Replace2.  So within your iLogic rule, once you've found the ComponentOccurrence you are targeting, and have stored it as the value of a variable (like oOcc), then you can use one of these methods like oOcc.Replace("FullFileName of Replacement document", True or False).

 

If you need a complete working iLogic rule which includes this method, we would need to know the component's name (as it is shown in the model browser), and the full file name (path, name, & file extension) of the other document you want to replace this one with, so we can fill out those 'input variables' that the method asks for, and whether or not to replace just that one occurrence, or all occurrences of it.

 

If this solved your problem, or answered your question, please click ACCEPT SOLUTION.
Or, if this helped you, please click (LIKE or KUDOS) 👍.

If you want and have time, I would appreciate your Vote(s) for My IDEAS 💡or you can Explore My CONTRIBUTIONS

Wesley Crihfield

EESignature

(Not an Autodesk Employee)