iLogic ChangeRow function in a reference to standard content center file

iLogic ChangeRow function in a reference to standard content center file

Anonymous
Not applicable
308 Views
1 Reply
Message 1 of 2

iLogic ChangeRow function in a reference to standard content center file

Anonymous
Not applicable

Hello,

 

I have a very simple assembly (as below):

 

10.png

 

I also have very simple iLogic rule:

 

Parameter("Tube:1", "OD") = OD

i = iPart.FindRow("Ring", "ID", "=", OD) iPart.ChangeRow("Ring", i )

 

It changes the size of the ring according to the tube outer diameter. Both parts changes simultaneously:

 

10.png

 

It works as long as Ring is an iPart. When I use a content center file instead (published from the same iPart) this code doesn't work anymore.

 

2017-11-25_18h20_39.png

 

It is just a simple example, but I think it shows clearly what I want to achieve. Please help.

 

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

MechMachineMan
Advisor
Advisor

If you understand that all an "iPart" does is create new files for each different size and hides those off in a folder, you'll realize a simple component replace command to the correct file is all you need.

 

There is also the limitation of modifying library parts, so your only bet is to do the replace as outlined in the link below.

 

https://forums.autodesk.com/t5/inventor-forum/changing-c-c-component-automation/td-p/2736623


--------------------------------------
Did you find this reply helpful ? If so please use the 'Accept as Solution' or 'Like' button below.

Justin K
Inventor 2018.2.3, Build 227 | Excel 2013+ VBA
ERP/CAD Communication | Custom Scripting
Machine Design | Process Optimization


iLogic/Inventor API: Autodesk Online Help | API Shortcut In Google Chrome | iLogic API Documentation
Vb.Net/VBA Programming: MSDN | Stackoverflow | Excel Object Model
Inventor API/VBA/Vb.Net Learning Resources: Forum Thread

Sample Solutions:Debugging in iLogic ( and Batch PDF Export Sample ) | API HasSaveCopyAs Issues |
BOM Export & Column Reorder | Reorient Skewed Part | Add Internal Profile Dogbones |
Run iLogic From VBA | Batch File Renaming| Continuous Pick/Rename Objects

Local Help: %PUBLIC%\Documents\Autodesk\Inventor 2018\Local Help

Ideas: Dockable/Customizable Property Browser | Section Line API/Thread Feature in Assembly/PartsList API Static Cells | Fourth BOM Type
0 Likes