Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
A.Acheson
in reply to: harland.jU5ZCW

The easiest method would be to use the ilogic API and the capture tool n the editor. 
Go to your part in the ilogic model browser right click and component add. This will process the code needed to add this specific occurrence. Use this as a guide only as you might not want to add this part on its own. 

In the ilogic snippet  browser you should find a function for content center replace of a component. This should allow you to replace one component for another and even allow multiple replacements within the sub assembly. 

Actually replacing all parts in all sub assemblies will be a little more difficult as you will need to dip into the Inventor API to start working with all the occurrence. See VBA sample of replacing one part manually picked.

I would suggest to work first with the ilogic API and just get a replacement of one part to happen. Then work from there. Post any code your having difficulty with. 

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