Edit

Share via


Word.GoToOptions interface

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.

Represents the options for the Selection.goTo and Document.goTo methods.

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

Properties

count

If provided, specifies the number of the item in the document. Only positive values are valid. The default value is 1.

direction

If provided, specifies the direction the range or selection is moved to. The default value is next.

item

If provided, specifies the kind of item the range or selection is moved to. The default value is page.

name

If provided, specifies the name if the item property is set to Word.GoToItem type bookmark, comment, field, or object.

Property Details

count

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.

If provided, specifies the number of the item in the document. Only positive values are valid. The default value is 1.

count?: number;

Property Value

number

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

direction

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.

If provided, specifies the direction the range or selection is moved to. The default value is next.

direction?: Word.GoToDirection | "First" | "Last" | "Next" | "Previous";

Property Value

Word.GoToDirection | "First" | "Last" | "Next" | "Previous"

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

item

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.

If provided, specifies the kind of item the range or selection is moved to. The default value is page.

item?: Word.GoToItem | "Bookmark" | "Comment" | "Endnote" | "Field" | "Footnote" | "Graphic" | "Heading" | "Line" | "Page" | "Section" | "Table" | "EmbeddedObject" | "Equation" | "Percent" | "SpellingError" | "GrammaticalError" | "ProofreadingError";

Property Value

Word.GoToItem | "Bookmark" | "Comment" | "Endnote" | "Field" | "Footnote" | "Graphic" | "Heading" | "Line" | "Page" | "Section" | "Table" | "EmbeddedObject" | "Equation" | "Percent" | "SpellingError" | "GrammaticalError" | "ProofreadingError"

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]

name

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.

If provided, specifies the name if the item property is set to Word.GoToItem type bookmark, comment, field, or object.

name?: string;

Property Value

string

Remarks

[ API set: WordApi BETA (PREVIEW ONLY) ]