Inventor iPart and iAssembly Factory part creation


When creating iParts and iAssemblies, one of the important things to remember is that Factory components need to be created.  Even though you see the data sitting in the iPart or iAssembly they do not physically exist on your local disk space and thus needs to be created.

As you can see in the above image you have created all your iAssembly assemblies but these do not exist on the hard disk.  If you are creating iAssemblies also make sure that you generate all the factory parts for your iParts as well

To do this open each part individually and using your shift select option, select all the table parts and right click and select Generate Factory parts.

Once this has been completed you will notice a folder with the name of the original part has been created in the same folder andit will contain all the generated factory parts.

If you open the iPart you will notice that you cannot edit anything.  This is basically a derived component which can only be changed from the template/original file that you created with the different configurations.

Please note that if any changes are made, you will need to regenerate the factory components to make sure everything is up to date.

When it comes to the iAssembly and generating the factory components, you will notice that you will be asked to click OK on

This is not ideal, but a quick search on the Autodesk Forums gave some iLogic code which saved all without any interruptions.

See below for this fantastic snippet.

'Shortcut for Inventor Application.
oApp = ThisApplication

'Shortcut for Document containing this rule.
oDoc = ThisDoc.Document

'Turn on Silent Operation to deactivate all pop-ups.
oApp.SilentOperation = True

'Turn on Error checking to skip to the end of the rule.
On Error GoTo jmpEndRule

'Start a transaction in the change manager to save on memory operations.
oTxn = oApp.TransactionManager.StartTransaction(oDoc, "iAssembly Generation")

'Shortcut for iAssembly Factory.
iAF = oDoc.ComponentDefinition.iAssemblyFactory

'Activate this code to generate all members in the Factory.
For Each oRow As iAssemblyTableRow In iAF.TableRows

'Activate this code to generate single members or a group of members based on row numbers.
'For i = 1 To 10 'Put the same number in both places to generate that single member.
'	iAF.CreateMember(i)

'End Transaction in the change manager.
jmpEndRule : oTxn.End

'Turn Silent Operation off to return user interface back to normal.
oApp.SilentOperation = False