<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Unable to export the current BOM config in Inventor Programming - iLogic, Macros, AddIns &amp; Apprentice</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780881#M80467</link>
    <description>What version of inventor are you using?</description>
    <pubDate>Thu, 15 Feb 2018 15:37:54 GMT</pubDate>
    <dc:creator>bradeneuropeArthur</dc:creator>
    <dc:date>2018-02-15T15:37:54Z</dc:date>
    <item>
      <title>Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780627#M80458</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I need to export a BOM to Excel, using a BOM XML template, but without modifying the BOM current structure.&lt;/P&gt;
&lt;P&gt;So I use :&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;save current BOM&amp;nbsp;config in "BOM Tempo.xml"&lt;/LI&gt;
&lt;LI&gt;load existing BOM config&lt;/LI&gt;
&lt;LI&gt;....&lt;/LI&gt;
&lt;LI&gt;load "BOM Tempo.xml"&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;The problem is the saved file "BOM Tempo.xml" does not match the current BOM config, it is always the same.&lt;/P&gt;
&lt;P&gt;The code I use :&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Sub test()

Set oAss = ThisApplication.ActiveDocument
Set oBOM = oAss.ComponentDefinition.BOM

'Define file name to export current BOM config
BOM_tempo = Environ("temp") &amp;amp; "\BOM_tempo.xml"

'if existing file, delete it
On Error Resume Next
Kill BOM_tempo
On Error GoTo 0

'Export active BOM config, in order to restore it 
Call oBOM.ExportBOMCustomization(BOM_tempo)

'Load the custom BOM config file
oBOM.ImportBOMCustomization ("c:\temp\custom BOM.xml")

'...some code...

'Restore the original BOM config file
Call oBOM.ImportBOMCustomization(BOM_tempo)

End Sub
&lt;/PRE&gt;
&lt;P&gt;Normally I should have the same BOM config that I had at the beginning...&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2018 14:40:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780627#M80458</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-15T14:40:25Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780881#M80467</link>
      <description>What version of inventor are you using?</description>
      <pubDate>Thu, 15 Feb 2018 15:37:54 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780881#M80467</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T15:37:54Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780890#M80468</link>
      <description>&lt;P&gt;2016 R3&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2018 15:40:17 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780890#M80468</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-15T15:40:17Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780892#M80469</link>
      <description>&lt;P&gt;hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;You are loading a different file:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;'Define file name to export current BOM config
&lt;FONT color="#ff0000"&gt;&lt;STRONG&gt;BOM_tempo = Environ("temp") &amp;amp; "\BOM_tempo.xml"&lt;/STRONG&gt;&lt;/FONT&gt;

'if existing file, delete it
On Error Resume Next
Kill BOM_tempo
On Error GoTo 0

'Export active BOM config, in order to restore it 
Call oBOM.ExportBOMCustomization(BOM_tempo)

'Load the custom BOM config file
&lt;FONT color="#ff0000"&gt;&lt;STRONG&gt;oBOM.ImportBOMCustomization ("c:\temp\custom BOM.xml")&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 15 Feb 2018 15:40:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780892#M80469</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T15:40:29Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780924#M80470</link>
      <description>&lt;P&gt;It is the right way :&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Define the name for CURRENT config --&amp;gt;&amp;nbsp;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;BOM_tempo.xml&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;Save current config in &lt;STRONG&gt;&lt;FONT color="#FF0000"&gt;BOM_tempo.xml&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;Load CUSTOM config --&amp;gt;&amp;nbsp;&lt;FONT color="#0000FF"&gt;&lt;STRONG&gt;custom BOM.xml&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;...some code...&lt;/LI&gt;
&lt;LI&gt;Restore the ORIGINAL config --&amp;gt; &lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;BOM_tempo.xml&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Thu, 15 Feb 2018 15:50:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780924#M80470</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-15T15:50:36Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780929#M80471</link>
      <description>&lt;PRE&gt;'Define file name to export current BOM config
&lt;FONT color="#ff0000"&gt;BOM_tempo = "c:\temp\custom BOM.xml"&lt;/FONT&gt;

'if existing file, delete it
On Error Resume Next
Kill BOM_tempo
On Error GoTo 0

'Export active BOM config, in order to restore it 
Call oBOM.ExportBOMCustomization(BOM_tempo)

'Load the custom BOM config file
oBOM.ImportBOMCustomization ("c:\temp\custom BOM.xml")&lt;/PRE&gt;</description>
      <pubDate>Thu, 15 Feb 2018 15:52:26 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780929#M80471</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T15:52:26Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780968#M80473</link>
      <description>&lt;UL&gt;
&lt;LI&gt;Save original in TEMPO&lt;/LI&gt;
&lt;LI&gt;Load CUSTOM&lt;/LI&gt;
&lt;LI&gt;...code...&lt;/LI&gt;
&lt;LI&gt;Restore TEMPO&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Thu, 15 Feb 2018 16:00:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780968#M80473</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-15T16:00:30Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780999#M80474</link>
      <description>&lt;P&gt;The following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Public Sub bomexp()
Dim a As Application
Set a = ThisApplication

Dim b As AssemblyDocument
Set b = a.ActiveDocument

Dim c As BOM
Set c = b.ComponentDefinition.BOM

c.ExportBOMCustomization ("D:\BomTemporare.xml")
b.Save
c.ImportBOMCustomization ("D:\BomCustom.xml")
b.Save
c.&lt;STRONG&gt;&lt;FONT color="#ff0000"&gt;Import&lt;/FONT&gt;&lt;/STRONG&gt;BOMCustomization ("D:\BomTemporare.xml")
b.Save
End Sub&lt;/PRE&gt;&lt;P&gt;&lt;FONT color="#ff0000"&gt;EDIT&lt;FONT color="#ff0000"&gt;.......................................................&lt;/FONT&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2018 16:16:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7780999#M80474</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T16:16:02Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781043#M80475</link>
      <description>&lt;P&gt;The edit works for me....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The save was the issue!&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2018 16:21:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781043#M80475</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T16:21:02Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781069#M80476</link>
      <description>&lt;PRE&gt;Sub test()

Set oAss = ThisApplication.ActiveDocument
Set oBOM = oAss.ComponentDefinition.BOM

'Define file name to export current BOM config
BOM_tempo = Environ("temp") &amp;amp; "\BOM_tempo.xml"

'if existing file, delete it
On Error Resume Next
Kill BOM_tempo
On Error GoTo 0

'Export active BOM config, in order to restore it 
Call oBOM.ExportBOMCustomization(BOM_tempo)
&lt;FONT color="#ff0000"&gt;oAss.save&lt;/FONT&gt;
'Load the custom BOM config file
oBOM.ImportBOMCustomization ("c:\temp\custom BOM.xml")
&lt;FONT color="#ff0000"&gt;oAss.save&lt;/FONT&gt;
'...some code...

'Restore the original BOM config file
Call oBOM.ImportBOMCustomization(BOM_tempo)
&lt;FONT color="#ff0000"&gt;oAss.save&lt;/FONT&gt;
End Sub&lt;/PRE&gt;&lt;P&gt;This should work for your code......&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2018 16:27:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781069#M80476</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T16:27:49Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781297#M80480</link>
      <description>&lt;P&gt;Sorry that don't work...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The problem is really with the VBA command "ExportBOMCustomization".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If I stop the code just before the line "Call oBOM.ExportBOMCustomization(BOM_tempo)", export manually the BOM config from Inventor, don't execute the line and continue the macro it's ok.&lt;/P&gt;</description>
      <pubDate>Thu, 15 Feb 2018 17:30:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781297#M80480</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-15T17:30:35Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781324#M80481</link>
      <description>Try my code for example.&lt;BR /&gt;You forgot to declare the assembly doc as assemblydocument as the bom as bom....</description>
      <pubDate>Thu, 15 Feb 2018 17:42:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781324#M80481</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T17:42:02Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781326#M80482</link>
      <description>That is the problem</description>
      <pubDate>Thu, 15 Feb 2018 17:42:21 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781326#M80482</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T17:42:21Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781331#M80483</link>
      <description>This worked perfect by me at least.</description>
      <pubDate>Thu, 15 Feb 2018 17:44:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7781331#M80483</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-15T17:44:12Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7783304#M80518</link>
      <description>&lt;P&gt;No, doesn't function, with or without exact declaration.&lt;/P&gt;</description>
      <pubDate>Fri, 16 Feb 2018 12:30:12 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7783304#M80518</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-16T12:30:12Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7783313#M80519</link>
      <description>Try my code. Does this work. Be sure that the file is deleted manually when the code is running</description>
      <pubDate>Fri, 16 Feb 2018 12:33:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7783313#M80519</guid>
      <dc:creator>bradeneuropeArthur</dc:creator>
      <dc:date>2018-02-16T12:33:23Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7783948#M80529</link>
      <description>&lt;P&gt;The exports worked just fine for me when I did a test run to get the desired results that you want (export with a new BOM Style, and revert the config back to the original).&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;This leaves me thinking you have 1 of 2 issues:&lt;/P&gt;
&lt;P&gt;1. Your 'some code' is undoing part of the process or somehow causing issues.&lt;/P&gt;
&lt;P&gt;2. Your&amp;nbsp;code to overwrite the BOM_tempo is not working properly and instead of storing the BOM config from the current file, it's just using a config version that had been saved in the past, which is the config you are seeing it restored to (instead of it's original config).&lt;/P&gt;</description>
      <pubDate>Fri, 16 Feb 2018 15:45:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7783948#M80529</guid>
      <dc:creator>MechMachineMan</dc:creator>
      <dc:date>2018-02-16T15:45:38Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7788224#M80579</link>
      <description>&lt;P&gt;Here is the exact code I used to test :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Sub test()

Set oAss = ThisApplication.ActiveDocument
Set oBOM = oAss.ComponentDefinition.BOM

'Define file name to export current BOM config
BOM_tempo = Environ("temp") &amp;amp; "\BOM_tempo.xml"

'if existing file, delete it
On Error Resume Next
Kill BOM_tempo
On Error GoTo 0

'1-Export active BOM config, in order to restore it 
Call oBOM.ExportBOMCustomization(BOM_tempo)

'2-Load the custom BOM config file
oBOM.ImportBOMCustomization ("c:\temp\custom BOM.xml")

'3-Restore the original BOM config file
Call oBOM.ImportBOMCustomization(BOM_tempo)

End Sub&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;Test procedure :&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Open an iam&lt;/LI&gt;
&lt;LI&gt;From Inventor, edit BOM and modify columns&lt;/LI&gt;
&lt;LI&gt;Close BOM&lt;/LI&gt;
&lt;LI&gt;Launch the program in debug mode&lt;/LI&gt;
&lt;LI&gt;STOP at 1&lt;/LI&gt;
&lt;LI&gt;Check BOM_tempo value and check date of the file BOM_tempo.xml --&amp;gt; it's ok&lt;/LI&gt;
&lt;LI&gt;Run and STOP at 2&lt;/LI&gt;
&lt;LI&gt;EXIT the program, go back to Inventor&lt;/LI&gt;
&lt;LI&gt;Open the BOM&lt;/LI&gt;
&lt;LI&gt;Load manually the file BOM_tempo.xml &lt;STRONG&gt;--&amp;gt; NOT ok&lt;/STRONG&gt;&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Mon, 19 Feb 2018 10:55:36 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7788224#M80579</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-19T10:55:36Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7788367#M80580</link>
      <description>&lt;P&gt;I found where is the bug:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;From Inventor, the BOM has 3 tabs : Model, Structured and Parts only.&lt;/LI&gt;
&lt;LI&gt;When you export manually, all the 3 tabs are exported&lt;/LI&gt;
&lt;LI&gt;When you export by VBA, only the Model tab is exported, and it is only that tab which is restored, on Model, Structured and Parts only.&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;To check it :&lt;/P&gt;
&lt;P&gt;1)VB export :&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;From Inventor, on an assembly, edit the BOM to have different configs on the 3 tabs&lt;/LI&gt;
&lt;LI&gt;Using the macro, export the BOM config and stop the program&lt;/LI&gt;
&lt;LI&gt;Manually, from Inventor, load the exported config :&amp;nbsp; you obtain same columns in all the 3 tabs&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;2)Manual export :&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;From Inventor, on an assembly, edit the BOM to have different configs on the 3 tabs&lt;/LI&gt;
&lt;LI&gt;Manually, export the BOM config to BOM_tempo.xml&lt;/LI&gt;
&lt;LI&gt;Manually, from Inventor, Edit and modify the BOM config&lt;/LI&gt;
&lt;LI&gt;Manually, import the BOM config from BOM_tempo.xml : you obtain the right config you saved&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 19 Feb 2018 12:05:38 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7788367#M80580</guid>
      <dc:creator>TONELLAL</dc:creator>
      <dc:date>2018-02-19T12:05:38Z</dc:date>
    </item>
    <item>
      <title>Re: Unable to export the current BOM config</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7791471#M80690</link>
      <description>&lt;P&gt;&lt;a href="https://forums.autodesk.com/t5/user/viewprofilepage/user-id/572775"&gt;@TONELLAL&lt;/a&gt;,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;By default, Model tab is exported. If you want to export Structured tab, need to enable and export the same. Similarly for Parts Only tab. So, there are 3 xml files to export and import. Below VBA code exports different excels for different tabs.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Public Sub BOMExport()
    ' Set a reference to the assembly document.
    ' This assumes an assembly document is active.
    Dim oDoc As AssemblyDocument
    Set oDoc = ThisApplication.ActiveDocument

    ' Set a reference to the BOM
    Dim oBOM As BOM
    Set oBOM = oDoc.ComponentDefinition.BOM
    
    ' Set the structured view to 'all levels'
    oBOM.StructuredViewFirstLevelOnly = False

    ' Make sure that the structured view is enabled.
    oBOM.StructuredViewEnabled = True

    ' Set a reference to the "Structured" BOMView
    Dim oStructuredBOMView As BOMView
    Set oStructuredBOMView = oBOM.BOMViews.Item("Structured")
    
    ' Export the BOM view to an Excel file
    oStructuredBOMView.Export "C:\temp\BOM-StructuredAllLevels.xls", kMicrosoftExcelFormat
  
    ' Make sure that the parts only view is enabled.
    oBOM.PartsOnlyViewEnabled = True

    ' Set a reference to the "Parts Only" BOMView
    Dim oPartsOnlyBOMView As BOMView
    Set oPartsOnlyBOMView = oBOM.BOMViews.Item("Parts Only")

    ' Export the BOM view to an Excel file
    oPartsOnlyBOMView.Export "C:\temp\BOM-PartsOnly.xls", kMicrosoftExcelFormat
End Sub&lt;/PRE&gt;
&lt;P&gt;Please feel free to contact if there is any queries.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;If solves problem, click on "Accept as solution" / give a "Kudo".&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks and regards,&lt;/P&gt;</description>
      <pubDate>Tue, 20 Feb 2018 12:39:37 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-ilogic/unable-to-export-the-current-bom-config/m-p/7791471#M80690</guid>
      <dc:creator>chandra.shekar.g</dc:creator>
      <dc:date>2018-02-20T12:39:37Z</dc:date>
    </item>
  </channel>
</rss>

