The Inventor API supports the ability to create an iPartFactory from a standard part (starting from Inventor 2008), access the iPart table, publish iPart members, insert iPart member in assemblies, create new rows in the iPart factory table, etc.
Once the iPart factory has been defined, the iPart members can be explicitly published or published when inserted into an assembly. To replace an iPart instance in an assembly, you can use ComponentOccurrence.ChangeRowOfiPartMember method directly.
The attached VBA sample demonstrates some of the iParts functionality. To run the sample, please copy attached folfer to the "C:\temp" folder or copy it to any location and change the hard-coded paths in the VBA project (the strFilePath string variable defines this path). The attachment also contains a standard factory “iPart_Standard.ipt” and a custom iPart factory "iPart_Custom.ipt" which are used in the sample. The sample shows how to publish iPart members, insert iPart members into an assembly, and replace one member with another item from the table by “ChangeRowOfiPartMember”.
All the sample files are created by R2014.
Detailed review of how iPart API can be used to create and manipulate iPart table content is posted here: