Skip to main content

Word.Bookmark

Word.Bookmark is an object type of the Word module (Office.word(iframe)). 5 methods.

Remarks​

Methods​

MethodDescription
delete()Deletes the bookmark.
exists()Returns whether the bookmark exists.
getName()Returns the bookmark name.
getRange()Returns the range at which the bookmark marker is placed.
goTo()Moves the cursor to the bookmark position.

Method details​

delete()​

Deletes the bookmark.

delete(): Promise<void>;

Returns

none

exists()​

Returns whether the bookmark exists.

exists(): Promise<boolean>;

Returns

Promise<boolean> - true if it exists

getName()​

Returns the bookmark name.

getName(): Promise<string>;

Returns

Promise<string> - bookmark name

getRange()​

Returns the range at which the bookmark marker is placed.

getRange(): Promise<Range>;

Returns

Promise<Range> - marker position range

goTo()​

Moves the cursor to the bookmark position. - Does not change document content; does nothing if the bookmark does not exist.

goTo(): Promise<void>;

Returns

none