Change this:
Code:
'Insert the Caption on the row below the picture
With oTbl.Cell(r + 1, c).Range
.Text = StrTxt
If .Characters.Last.Previous.Information(wdVerticalPositionRelativeToPage) <> _
.Characters.First.Information(wdVerticalPositionRelativeToPage) Then
.FitTextWidth = ColWdth - CentimetersToPoints(0.3)
End If
End With
to this:
Code:
'Insert the Caption on the row below the picture
With oTbl.Cell(r + 1, c)
.LeftPadding = CentimetersToPoints(0.15)
.RightPadding = CentimetersToPoints(0.15)
With .Range
.Text = StrTxt
If .Characters.Last.Previous.Information(wdVerticalPositionRelativeToPage) <> _
.Characters.First.Information(wdVerticalPositionRelativeToPage) Then
.FitTextWidth = ColWdth - CentimetersToPoints(0.3)
End If
End With
End With