Edit

Share via


Word.Interfaces.RangeCollectionLoadOptions interface

Contains a collection of Word.Range objects.

Remarks

[ API set: WordApi 1.1 ]

Properties

$all

Specifying $all for the load options loads all the scalar properties (such as Range.address) but not the navigational properties (such as Range.format.fill.color).

font

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

hasNoProofing

For EACH ITEM in the collection: Specifies the proofing status (spelling and grammar checking) of the range.

hyperlink

For EACH ITEM in the collection: Gets the first hyperlink in the range, or sets a hyperlink on the range. All hyperlinks in the range are deleted when you set a new hyperlink on the range. Use a '#' to separate the address part from the optional location part.

isEmpty

For EACH ITEM in the collection: Checks whether the range length is zero.

languageDetected

For EACH ITEM in the collection: Specifies whether Microsoft Word has detected the language of the text in the range.

languageId

For EACH ITEM in the collection: Specifies a LanguageId value that represents the language for the range.

languageIdFarEast

For EACH ITEM in the collection: Specifies an East Asian language for the range.

languageIdOther

For EACH ITEM in the collection: Specifies a language for the range that isn't classified as an East Asian language.

listFormat

For EACH ITEM in the collection: Returns a ListFormat object that represents all the list formatting characteristics of the range.

parentBody

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

parentContentControl

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

parentContentControlOrNullObject

For EACH ITEM in the collection: Gets the currently supported content control that contains the range. If there isn't a parent content control, then this method will return an object with its isNullObject property set to true. For further information, see *OrNullObject methods and properties.

parentTable

For EACH ITEM in the collection: Gets the table that contains the range. Throws an ItemNotFound error if it isn't contained in a table.

parentTableCell

For EACH ITEM in the collection: Gets the table cell that contains the range. Throws an ItemNotFound error if it isn't contained in a table cell.

parentTableCellOrNullObject

For EACH ITEM in the collection: Gets the table cell that contains the range. If it isn't contained in a table cell, then this method will return an object with its isNullObject property set to true. For further information, see *OrNullObject methods and properties.

parentTableOrNullObject

For EACH ITEM in the collection: Gets the table that contains the range. If it isn't contained in a table, then this method will return an object with its isNullObject property set to true. For further information, see *OrNullObject methods and properties.

shading

For EACH ITEM in the collection: Returns a ShadingUniversal object that refers to the shading formatting for the range.

style

For EACH ITEM in the collection: Specifies the style name for the range. 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.

styleBuiltIn

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

text

For EACH ITEM in the collection: Gets the text of the range.

Property Details

$all

Specifying $all for the load options loads all the scalar properties (such as Range.address) but not the navigational properties (such as Range.format.fill.color).

$all?: boolean;

Property Value

boolean

font

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

font?: Word.Interfaces.FontLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.1 ]

hasNoProofing

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

For EACH ITEM in the collection: Specifies the proofing status (spelling and grammar checking) of the range.

hasNoProofing?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

For EACH ITEM in the collection: Gets the first hyperlink in the range, or sets a hyperlink on the range. All hyperlinks in the range are deleted when you set a new hyperlink on the range. Use a '#' to separate the address part from the optional location part.

hyperlink?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi 1.3 ]

isEmpty

For EACH ITEM in the collection: Checks whether the range length is zero.

isEmpty?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi 1.3 ]

languageDetected

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

For EACH ITEM in the collection: Specifies whether Microsoft Word has detected the language of the text in the range.

languageDetected?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

languageId

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

For EACH ITEM in the collection: Specifies a LanguageId value that represents the language for the range.

languageId?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

languageIdFarEast

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

For EACH ITEM in the collection: Specifies an East Asian language for the range.

languageIdFarEast?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

languageIdOther

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

For EACH ITEM in the collection: Specifies a language for the range that isn't classified as an East Asian language.

languageIdOther?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

listFormat

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

For EACH ITEM in the collection: Returns a ListFormat object that represents all the list formatting characteristics of the range.

listFormat?: Word.Interfaces.ListFormatLoadOptions;

Property Value

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

parentBody

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

parentBody?: Word.Interfaces.BodyLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.3 ]

parentContentControl

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

parentContentControl?: Word.Interfaces.ContentControlLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.1 ]

parentContentControlOrNullObject

For EACH ITEM in the collection: Gets the currently supported content control that contains the range. If there isn't a parent content control, then this method will return an object with its isNullObject property set to true. For further information, see *OrNullObject methods and properties.

parentContentControlOrNullObject?: Word.Interfaces.ContentControlLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.3 ]

parentTable

For EACH ITEM in the collection: Gets the table that contains the range. Throws an ItemNotFound error if it isn't contained in a table.

parentTable?: Word.Interfaces.TableLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.3 ]

parentTableCell

For EACH ITEM in the collection: Gets the table cell that contains the range. Throws an ItemNotFound error if it isn't contained in a table cell.

parentTableCell?: Word.Interfaces.TableCellLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.3 ]

parentTableCellOrNullObject

For EACH ITEM in the collection: Gets the table cell that contains the range. If it isn't contained in a table cell, then this method will return an object with its isNullObject property set to true. For further information, see *OrNullObject methods and properties.

parentTableCellOrNullObject?: Word.Interfaces.TableCellLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.3 ]

parentTableOrNullObject

For EACH ITEM in the collection: Gets the table that contains the range. If it isn't contained in a table, then this method will return an object with its isNullObject property set to true. For further information, see *OrNullObject methods and properties.

parentTableOrNullObject?: Word.Interfaces.TableLoadOptions;

Property Value

Remarks

[ API set: WordApi 1.3 ]

shading

Note

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

For EACH ITEM in the collection: Returns a ShadingUniversal object that refers to the shading formatting for the range.

shading?: Word.Interfaces.ShadingUniversalLoadOptions;

Property Value

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

style

For EACH ITEM in the collection: Specifies the style name for the range. 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.

style?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi 1.1 ]

styleBuiltIn

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

styleBuiltIn?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi 1.3 ]

text

For EACH ITEM in the collection: Gets the text of the range.

text?: boolean;

Property Value

boolean

Remarks

[ API set: WordApi 1.1 ]