This example displays the name ("Microsoft Excel Worksheet," for example) and caption label ("Figure," for example) for each item that has a caption added automatically when inserted.
For Each myCaption In AutoCaptions
If myCaption.AutoInsert = True Then MsgBox myCaption.Name _
& vbCr & "Label = " & myCaption.CaptionLabel.Name
Next myCaption
This example sets the caption label for Word tables to "Table" and then inserts a new table immediately after the selection.
With AutoCaptions("Microsoft Word Table")
.AutoInsert = True
.CaptionLabel = wdCaptionTable
End With
Selection.Collapse Direction:=wdCollapseEnd
ActiveDocument.Tables.Add Range:=Selection.Range, NumRows:=2, _
NumColumns:=3