T
Terry Moriarty
I'm getting an error of "Error! No text of specified style
in document" when I insert a table caption for a table.
I insert a new table, format the header and insert the
caption whenever Category Name in my data source changes.
Then I fill in the table with rows until the category name
changes again.
Every thing is working except for this insertcaption error
in my document.
The code is below.
Thanks is advance for any assistance any one can provide
me,
Terry Moriarty
target.Tables.Add Range:=myRange, NumRows:=1,
NumColumns:=k - 1
currentTable = currentTable + 1
Set ttab = target.Tables(currentTable)
ttab.Select
With ttab.Borders
.InsideLineStyle = wdLineStyleSingle
.OutsideLineStyle = wdLineStyleSingle
End With
' Insert the Caption for the Table
ttab.Range.InsertCaption Label:=wdCaptionTable, _
Title:=": " & CurrentCat, _
Position:=wdCaptionPositionAbove
in document" when I insert a table caption for a table.
I insert a new table, format the header and insert the
caption whenever Category Name in my data source changes.
Then I fill in the table with rows until the category name
changes again.
Every thing is working except for this insertcaption error
in my document.
The code is below.
Thanks is advance for any assistance any one can provide
me,
Terry Moriarty
target.Tables.Add Range:=myRange, NumRows:=1,
NumColumns:=k - 1
currentTable = currentTable + 1
Set ttab = target.Tables(currentTable)
ttab.Select
With ttab.Borders
.InsideLineStyle = wdLineStyleSingle
.OutsideLineStyle = wdLineStyleSingle
End With
' Insert the Caption for the Table
ttab.Range.InsertCaption Label:=wdCaptionTable, _
Title:=": " & CurrentCat, _
Position:=wdCaptionPositionAbove