<?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: iLogic Error in Inventor Forum</title>
    <link>https://forums.autodesk.com/t5/inventor-forum/ilogic-error/m-p/5787875#M363668</link>
    <description>&lt;P&gt;I have a really good idea what's wrong. But I'm going to let you figure it out.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Look at your error windows and read.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;One of the lines sticks out as familiar - "get.BomStructure"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This tells us it's either that function or something invoked by/related to that function.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Run a basic name check of the occurrences and let me know how that goes.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Let me know if you see anything weird.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;Public Sub Main()

    ' Get the active assembly. 
    Dim oAsmDoc As AssemblyDocument 
    oAsmDoc = ThisApplication.ActiveDocument 
    
    
    Call TraverseAssembly(oAsmDoc.ComponentDefinition.Occurrences, 1)

End Sub 

Private Sub TraverseAssembly(Occurrences As ComponentOccurrences, _ 
                             Level As Integer) 
    
    Dim oOcc As ComponentOccurrence 
    For Each oOcc In Occurrences 
              MsgBox(oOcc.Name
 
 ' Check to see if this occurrence represents a subassembly 
        ' and recursively call this function to traverse through it. 
        If oOcc.DefinitionDocumentType = DocumentTypeEnum.kAssemblyDocumentObject Then
            Call TraverseAssembly(oOcc.SubOccurrences, Level + 1) 
        End If 
    Next
End Sub&lt;/PRE&gt;</description>
    <pubDate>Tue, 25 Aug 2015 23:04:17 GMT</pubDate>
    <dc:creator>MechMachineMan</dc:creator>
    <dc:date>2015-08-25T23:04:17Z</dc:date>
  </channel>
</rss>

