<?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: CustomTable, detect if split in Inventor Programming Forum</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-forum/customtable-detect-if-split/m-p/6299422#M110310</link>
    <description>&lt;P&gt;Hi Stan,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am not finding a property on a CustomTable object that will tell if it is split or not.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I see that if a CustomTable is split then there is a node in the browser for the split part of the table. In my quick test the VBA code below is determining if a table with the title "Employees" was split. Maybe this could be a work around. It checks to see if the native object for the BrowserNode is a CustomTable.&amp;nbsp; I am not sure of your workflow and maybe you would not need to do this test. (you could just check the number of BrowserNodes it has)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Public Sub customTableIsSlpit_UsingBrowserPaneTest()
    Dim oDrwDoc As DrawingDocument
    Set oDrwDoc = ThisApplication.ActiveDocument
    
    Debug.Print oDrwDoc.ActiveSheet.CustomTables.count

    Dim oBrowserPane As BrowserPane
    Set oBrowserPane = oDrwDoc.BrowserPanes.ActivePane

    Dim oTopBrowserNode As BrowserNode
    Set oTopBrowserNode = oBrowserPane.TopNode
   
    Dim oBrowserNode As BrowserNode
    
    For Each oBrowserNode In oTopBrowserNode.BrowserNodes
     If oBrowserNode.BrowserNodeDefinition.Label = "Sheet:1" Then
        
        Dim oBrowserNode2 As BrowserNode
        For Each oBrowserNode2 In oBrowserNode.BrowserNodes
               
          If oBrowserNode2.BrowserNodeDefinition.Label = "Employees" Then
                      
            Dim oNativeObject As Object
            Set oNativeObject = oBrowserNode2.NativeObject

            If TypeName(oNativeObject) = "CustomTable" Then
                If oBrowserNode2.BrowserNodes.count &amp;gt; 0 Then
                    MsgBox "Custom Table is split"
                Else
                   MsgBox "Custom Table is NOT split"
                End If
                Exit For
            End If
         End If ' If label = "Employees"
       Next
      End If ' If label = "Sheet:1"
    Next
       
End Sub&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Wayne&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 28 Apr 2016 23:53:48 GMT</pubDate>
    <dc:creator>wayne.brill</dc:creator>
    <dc:date>2016-04-28T23:53:48Z</dc:date>
    <item>
      <title>CustomTable, detect if split</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/customtable-detect-if-split/m-p/6293172#M110309</link>
      <description>&lt;P&gt;Inventor 2017, VS 2015, VB.net addin&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My addin&amp;nbsp;creates a CustomTable.&amp;nbsp;The addin can update this table and any copies made of the table as data changes. It does this by looking at&amp;nbsp;the CustomTables and replacing the rows of each table with a matching title.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Problem comes when I manually split the table (right click table,Table,Split Table). My addin then sees two tables&amp;nbsp;and tries to update both. I can not find a way to detect if the second table is a copy of first that also needs its data updated or&amp;nbsp;is&amp;nbsp;split off the&amp;nbsp;original table. If I try to&amp;nbsp;change the split section inventor exits to desktop (I assume this is a bug in inventor).&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My workaround is to gather&amp;nbsp;properties about&amp;nbsp;each matching table and delete it&amp;nbsp;which will delete any split off sections.&amp;nbsp;After I use the properties gathered to&amp;nbsp;recreate the tables. But I have to then&amp;nbsp;manually&amp;nbsp;recreate the splits that are sometimes necessary.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;So... how&amp;nbsp;do&amp;nbsp;I&amp;nbsp;deal with split CustomTables?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Stan&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 26 Apr 2016 13:10:46 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/customtable-detect-if-split/m-p/6293172#M110309</guid>
      <dc:creator>sellis</dc:creator>
      <dc:date>2016-04-26T13:10:46Z</dc:date>
    </item>
    <item>
      <title>Re: CustomTable, detect if split</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/customtable-detect-if-split/m-p/6299422#M110310</link>
      <description>&lt;P&gt;Hi Stan,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am not finding a property on a CustomTable object that will tell if it is split or not.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I see that if a CustomTable is split then there is a node in the browser for the split part of the table. In my quick test the VBA code below is determining if a table with the title "Employees" was split. Maybe this could be a work around. It checks to see if the native object for the BrowserNode is a CustomTable.&amp;nbsp; I am not sure of your workflow and maybe you would not need to do this test. (you could just check the number of BrowserNodes it has)&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;Public Sub customTableIsSlpit_UsingBrowserPaneTest()
    Dim oDrwDoc As DrawingDocument
    Set oDrwDoc = ThisApplication.ActiveDocument
    
    Debug.Print oDrwDoc.ActiveSheet.CustomTables.count

    Dim oBrowserPane As BrowserPane
    Set oBrowserPane = oDrwDoc.BrowserPanes.ActivePane

    Dim oTopBrowserNode As BrowserNode
    Set oTopBrowserNode = oBrowserPane.TopNode
   
    Dim oBrowserNode As BrowserNode
    
    For Each oBrowserNode In oTopBrowserNode.BrowserNodes
     If oBrowserNode.BrowserNodeDefinition.Label = "Sheet:1" Then
        
        Dim oBrowserNode2 As BrowserNode
        For Each oBrowserNode2 In oBrowserNode.BrowserNodes
               
          If oBrowserNode2.BrowserNodeDefinition.Label = "Employees" Then
                      
            Dim oNativeObject As Object
            Set oNativeObject = oBrowserNode2.NativeObject

            If TypeName(oNativeObject) = "CustomTable" Then
                If oBrowserNode2.BrowserNodes.count &amp;gt; 0 Then
                    MsgBox "Custom Table is split"
                Else
                   MsgBox "Custom Table is NOT split"
                End If
                Exit For
            End If
         End If ' If label = "Employees"
       Next
      End If ' If label = "Sheet:1"
    Next
       
End Sub&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Wayne&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 28 Apr 2016 23:53:48 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/customtable-detect-if-split/m-p/6299422#M110310</guid>
      <dc:creator>wayne.brill</dc:creator>
      <dc:date>2016-04-28T23:53:48Z</dc:date>
    </item>
    <item>
      <title>Re: CustomTable, detect if split</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/customtable-detect-if-split/m-p/6303394#M110311</link>
      <description>&lt;P&gt;I can&amp;nbsp;work with this...&amp;nbsp;will just use the browser nodes to select the CustomTable I want to update.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks!&lt;/P&gt;</description>
      <pubDate>Mon, 02 May 2016 11:22:30 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/customtable-detect-if-split/m-p/6303394#M110311</guid>
      <dc:creator>sellis</dc:creator>
      <dc:date>2016-05-02T11:22:30Z</dc:date>
    </item>
  </channel>
</rss>

