Tables within tables

K

komentr

I have a table of tables and cannot figure out how to access the information
within the subtables. Any examples would be greatly appreciated.
 
J

Jean-Guy Marcil

komentr was telling us:
komentr nous racontait que :
I have a table of tables and cannot figure out how to access the
information within the subtables. Any examples would be greatly
appreciated.

Here is one way:

Dim tblParent As Table
Dim tblSub As Table
Dim cellTarget As Cell

Set tblParent = ActiveDocument.Tables(1)
With tblParent
Set cellTarget = .Cell(2, 3)
With cellTarget
Set tblSub = .Tables(1)
End With
End With

With tblSub
.Range.Font.Size = 10
.Borders(wdBorderHorizontal) _
.LineStyle = wdLineStyleDashLargeGap
End With
 
Top