Word.Interfaces.ContentControlCollectionLoadOptions interface

Contains a collection of Word.ContentControl objects. Content controls are bounded and potentially labeled regions in a document that serve as containers for specific types of content. Individual content controls may contain contents such as images, tables, or paragraphs of formatted text. Currently, only rich text content controls are supported.

[ API set: WordApi 1.1 ]

Properties

$all
appearance

For EACH ITEM in the collection: Gets or sets the appearance of the content control. The value can be 'BoundingBox', 'Tags', or 'Hidden'.

[ API set: WordApi 1.1 ]

cannotDelete

For EACH ITEM in the collection: Gets or sets a value that indicates whether the user can delete the content control. Mutually exclusive with removeWhenEdited.

[ API set: WordApi 1.1 ]

cannotEdit

For EACH ITEM in the collection: Gets or sets a value that indicates whether the user can edit the contents of the content control.

[ API set: WordApi 1.1 ]

color

For EACH ITEM in the collection: Gets or sets the color of the content control. Color is specified in '#RRGGBB' format or by using the color name.

[ API set: WordApi 1.1 ]

font

For EACH ITEM in the collection: Gets the text format of the content control. Use this to get and set font name, size, color, and other properties.

[ API set: WordApi 1.1 ]

id

For EACH ITEM in the collection: Gets an integer that represents the content control identifier. Read-only.

[ API set: WordApi 1.1 ]

parentBody

For EACH ITEM in the collection: Gets the parent body of the content control.

[ API set: WordApi 1.3 ]

parentContentControl

For EACH ITEM in the collection: Gets the content control that contains the content control. Throws an error if there isn't a parent content control.

[ API set: WordApi 1.1 ]

parentContentControlOrNullObject

For EACH ITEM in the collection: Gets the content control that contains the content control. Returns a null object if there isn't a parent content control.

[ API set: WordApi 1.3 ]

parentTable

For EACH ITEM in the collection: Gets the table that contains the content control. Throws an error if it is not contained in a table.

[ API set: WordApi 1.3 ]

parentTableCell

For EACH ITEM in the collection: Gets the table cell that contains the content control. Throws an error if it is not contained in a table cell.

[ API set: WordApi 1.3 ]

parentTableCellOrNullObject

For EACH ITEM in the collection: Gets the table cell that contains the content control. Returns a null object if it is not contained in a table cell.

[ API set: WordApi 1.3 ]

parentTableOrNullObject

For EACH ITEM in the collection: Gets the table that contains the content control. Returns a null object if it is not contained in a table.

[ API set: WordApi 1.3 ]

placeholderText

For EACH ITEM in the collection: Gets or sets the placeholder text of the content control. Dimmed text will be displayed when the content control is empty.

[ API set: WordApi 1.1 ]

removeWhenEdited

For EACH ITEM in the collection: Gets or sets a value that indicates whether the content control is removed after it is edited. Mutually exclusive with cannotDelete.

[ API set: WordApi 1.1 ]

style

For EACH ITEM in the collection: Gets or sets the style name for the content control. Use this property for custom styles and localized style names. To use the built-in styles that are portable between locales, see the "styleBuiltIn" property.

[ API set: WordApi 1.1 ]

styleBuiltIn

For EACH ITEM in the collection: Gets or sets the built-in style name for the content control. Use this property for built-in styles that are portable between locales. To use custom styles or localized style names, see the "style" property.

[ API set: WordApi 1.3 ]

subtype

For EACH ITEM in the collection: Gets the content control subtype. The subtype can be 'RichTextInline', 'RichTextParagraphs', 'RichTextTableCell', 'RichTextTableRow' and 'RichTextTable' for rich text content controls. Read-only.

[ API set: WordApi 1.3 ]

tag

For EACH ITEM in the collection: Gets or sets a tag to identify a content control.

[ API set: WordApi 1.1 ]

text

For EACH ITEM in the collection: Gets the text of the content control. Read-only.

[ API set: WordApi 1.1 ]

title

For EACH ITEM in the collection: Gets or sets the title for a content control.

[ API set: WordApi 1.1 ]

type

For EACH ITEM in the collection: Gets the content control type. Only rich text content controls are supported currently. Read-only.

[ API set: WordApi 1.1 ]

Property Details

$all

$all?: boolean;

Property Value

boolean

appearance

For EACH ITEM in the collection: Gets or sets the appearance of the content control. The value can be 'BoundingBox', 'Tags', or 'Hidden'.

[ API set: WordApi 1.1 ]

appearance?: boolean;

Property Value

boolean

cannotDelete

For EACH ITEM in the collection: Gets or sets a value that indicates whether the user can delete the content control. Mutually exclusive with removeWhenEdited.

[ API set: WordApi 1.1 ]

cannotDelete?: boolean;

Property Value

boolean

cannotEdit

For EACH ITEM in the collection: Gets or sets a value that indicates whether the user can edit the contents of the content control.

[ API set: WordApi 1.1 ]

cannotEdit?: boolean;

Property Value

boolean

color

For EACH ITEM in the collection: Gets or sets the color of the content control. Color is specified in '#RRGGBB' format or by using the color name.

[ API set: WordApi 1.1 ]

color?: boolean;

Property Value

boolean

font

For EACH ITEM in the collection: Gets the text format of the content control. Use this to get and set font name, size, color, and other properties.

[ API set: WordApi 1.1 ]

font?: Word.Interfaces.FontLoadOptions;

Property Value

id

For EACH ITEM in the collection: Gets an integer that represents the content control identifier. Read-only.

[ API set: WordApi 1.1 ]

id?: boolean;

Property Value

boolean

parentBody

For EACH ITEM in the collection: Gets the parent body of the content control.

[ API set: WordApi 1.3 ]

parentBody?: Word.Interfaces.BodyLoadOptions;

Property Value

parentContentControl

For EACH ITEM in the collection: Gets the content control that contains the content control. Throws an error if there isn't a parent content control.

[ API set: WordApi 1.1 ]

parentContentControl?: Word.Interfaces.ContentControlLoadOptions;

Property Value

parentContentControlOrNullObject

For EACH ITEM in the collection: Gets the content control that contains the content control. Returns a null object if there isn't a parent content control.

[ API set: WordApi 1.3 ]

parentContentControlOrNullObject?: Word.Interfaces.ContentControlLoadOptions;

Property Value

parentTable

For EACH ITEM in the collection: Gets the table that contains the content control. Throws an error if it is not contained in a table.

[ API set: WordApi 1.3 ]

parentTable?: Word.Interfaces.TableLoadOptions;

Property Value

parentTableCell

For EACH ITEM in the collection: Gets the table cell that contains the content control. Throws an error if it is not contained in a table cell.

[ API set: WordApi 1.3 ]

parentTableCell?: Word.Interfaces.TableCellLoadOptions;

Property Value

parentTableCellOrNullObject

For EACH ITEM in the collection: Gets the table cell that contains the content control. Returns a null object if it is not contained in a table cell.

[ API set: WordApi 1.3 ]

parentTableCellOrNullObject?: Word.Interfaces.TableCellLoadOptions;

Property Value

parentTableOrNullObject

For EACH ITEM in the collection: Gets the table that contains the content control. Returns a null object if it is not contained in a table.

[ API set: WordApi 1.3 ]

parentTableOrNullObject?: Word.Interfaces.TableLoadOptions;

Property Value

placeholderText

For EACH ITEM in the collection: Gets or sets the placeholder text of the content control. Dimmed text will be displayed when the content control is empty.

[ API set: WordApi 1.1 ]

placeholderText?: boolean;

Property Value

boolean

removeWhenEdited

For EACH ITEM in the collection: Gets or sets a value that indicates whether the content control is removed after it is edited. Mutually exclusive with cannotDelete.

[ API set: WordApi 1.1 ]

removeWhenEdited?: boolean;

Property Value

boolean

style

For EACH ITEM in the collection: Gets or sets the style name for the content control. Use this property for custom styles and localized style names. To use the built-in styles that are portable between locales, see the "styleBuiltIn" property.

[ API set: WordApi 1.1 ]

style?: boolean;

Property Value

boolean

styleBuiltIn

For EACH ITEM in the collection: Gets or sets the built-in style name for the content control. Use this property for built-in styles that are portable between locales. To use custom styles or localized style names, see the "style" property.

[ API set: WordApi 1.3 ]

styleBuiltIn?: boolean;

Property Value

boolean

subtype

For EACH ITEM in the collection: Gets the content control subtype. The subtype can be 'RichTextInline', 'RichTextParagraphs', 'RichTextTableCell', 'RichTextTableRow' and 'RichTextTable' for rich text content controls. Read-only.

[ API set: WordApi 1.3 ]

subtype?: boolean;

Property Value

boolean

tag

For EACH ITEM in the collection: Gets or sets a tag to identify a content control.

[ API set: WordApi 1.1 ]

tag?: boolean;

Property Value

boolean

text

For EACH ITEM in the collection: Gets the text of the content control. Read-only.

[ API set: WordApi 1.1 ]

text?: boolean;

Property Value

boolean

title

For EACH ITEM in the collection: Gets or sets the title for a content control.

[ API set: WordApi 1.1 ]

title?: boolean;

Property Value

boolean

type

For EACH ITEM in the collection: Gets the content control type. Only rich text content controls are supported currently. Read-only.

[ API set: WordApi 1.1 ]

type?: boolean;

Property Value

boolean