Microsoft Word Suite
278
Command: insert caption
Inserts a caption immediately preceding or following the specified range or selection.
Syntax
insert caption
at Required. An expression that returns a text range object.
caption label enumeration Required. The caption label to be inserted. Can be a string or one of
the following: caption equation, caption figure, or caption table. If the label hasnt yet been
defined, an error occurs. To define new caption labels, use the make command with the
caption label class.
[title Unicode text] Optional. The string to be inserted immediately following the label in the
caption.
[caption position enumeration] Optional. Specifies whether the caption will be inserted above
or below the text range object. Can be either of the following: caption position above or
caption position below.
Example
This example inserts a caption below the first table in the active document.
insert caption at text object of table 1 of active document caption label ¬
caption table caption position caption position below
This example inserts a Figure caption at the insertion point.
collapse range text object of selection direction collapse start
insert caption at text object of selection caption label caption figure ¬
title ": Sales Results" caption position caption position below
Command: insert cells
Adds cells to an existing table. The number of cells inserted is equal to the number of cells in the
selection.
Syntax
insert cells selection Required. An expression that returns a selection object.
[shift cells enumeration] Optional. Can be one of the following:
Constant
Description
insert cells entire column Inserts an entire column to the left of the column that contains
the selection.
insert cells entire row
Inserts an entire row above the row that contains the selection.
insert cells shift down
Inserts new cells above the selected cells.
insert cells shift right
Insert new cells to the left of the selected cells.