Conversion of Inventor older templates to newer templates

Conversion of Inventor older templates to newer templates

vijayakumar.packiyanathan
Advocate Advocate
358 Visites
1 Réponse
Message 1 sur 2

Conversion of Inventor older templates to newer templates

vijayakumar.packiyanathan
Advocate
Advocate

Hello,

 

Please check the below link regarding query which was posted in Inventor board forum page:

https://forums.autodesk.com/t5/inventor-forum/convert-migrate-older-inventor-templates-to-newer-temp...

 

As per @SBix26 reply, it is worked and meetup my needed requirement. But I am performing this for multiple files as one by one. It is tedious process and it is time consuming.

 

So, is there any iLogic solution to automate the process of convert older templates to newer templates.

 

Thank you.

0 J'aime
359 Visites
1 Réponse
Reply (1)
Message 2 sur 2

A.Acheson
Mentor
Mentor

Here is a post showing code for export/import of BOM xml settings written in VBA. 

You can export the xml settings manually then use import code to import whenever you need. Here is the API helpfile for BOM import method and here is the BOM property of component definition.

Code converted to VB.NET for ilogic environment. 

 

Sub Main
    BOM_ColumnCustomizasion_Import
End Sub
Sub BOM_ColumnCustomizasion_Import ()

    Dim oAsmDoc As AssemblyDocument
    oAsmDoc = ThisApplication.ActiveDocument
    Dim oAsmDef As AssemblyComponentDefinition
    oAsmDef = oAsmDoc.ComponentDefinition
    
    Dim oBOM As BOM
    oBOM = oAsmDef.BOM
    
    Dim filename As String    'assume the file exists
    filename = "c:\temp\BOM_Columns.xml"  
    oBOM.ImportBOMCustomization(filename)

End Sub

 

 

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