How to select BOM table from FeatureTree?

Hello,

I have got some macro, which transverse the FeatureTree and select BOM (first I load all BOM's to ListBox, select BOM in ListBox and if the name of BOM is the same as the name in FeatureTree, BOM is selected).

I need selecet data in BOM or load it (maybe) via TableAnnotation function.

Dim swApp                  As SldWorks.SldWorks

Dim swModel               As SldWorks.ModelDoc2

Dim swDraw                 As SldWorks.DrawingDoc

Dim swFeat                  As SldWorks.Feature

Dim BOMName            As String

Dim swFileName          As String

  

Set swApp = Application.SldWorks

Set swModel = swApp.ActiveDoc

Set swDrawingsDoc = swApp.ActiveDoc

Set swFeat = swModel.FirstFeature

     While Not swFeat Is Nothing

        BOMName = swFeat.Name

            If BOMName = UserFormExpBom.ListBoxBOM.Value Then

                swFeat.Select True

            End If

        Set swFeat = swFeat.GetNextFeature

    Wend

This is only part of my code. How can I select data in BOM table? This code select only table, but not data in table. I need copy data from table to excel... I need select data in table first.

Thnak you.

SolidworksApi macros