Word.Note
Word.Note is an object type of the Word module (Office.word(iframe)). 7 methods.
Remarks
- Module: Word ·
Office.word(iframe)· namespaceWord - Obtained from:
Document.getEndnotes(),Document.getFootnotes(),Document.getNote(noteId),Document.getNotes(),Body.getEndnotes(),Body.getFootnotes(),Body.getNotes(),Paragraph.getEndnotes(),Paragraph.getFootnotes(),Paragraph.getNotes(),Paragraph.insertEndnote(text, options),Paragraph.insertFootnote(text, options),Range.getEndnotes(),Range.getFootnotes(),Range.getNotes(),Range.insertEndnote(text),Range.insertFootnote(text) - Every method returns a
Promise; signatures use TypeScript notation.
Methods
| Method | Description |
|---|---|
delete() | Deletes the footnote/endnote. |
exists() | Returns whether the footnote/endnote exists. |
getBody() | Returns the content area of the footnote/endnote. |
getId() | Returns the footnote/endnote ID. |
getIndex() | Returns the ordinal position among footnotes/endnotes of the same kind within the document. |
getRange() | Returns the body range at which the footnote/endnote reference mark is placed. |
getType() | Returns whether this is a footnote or an endnote. |
Method details
delete()
Deletes the footnote/endnote. - Deletes both the reference mark in the body and the footnote/endnote content.
delete(): Promise<void>;
Returns
none
exists()
Returns whether the footnote/endnote exists.
exists(): Promise<boolean>;
Returns
Promise<boolean> - true if it exists
getBody()
Returns the content area of the footnote/endnote.
getBody(): Promise<Body>;
Returns
Promise<Body> - content area, null if none
getId()
Returns the footnote/endnote ID.
getId(): Promise<string>;
Returns
Promise<string> - footnote/endnote ID
getIndex()
Returns the ordinal position among footnotes/endnotes of the same kind within the document.
getIndex(): Promise<number>;
Returns
Promise<number> - ordinal position, -1 if none
getRange()
Returns the body range at which the footnote/endnote reference mark is placed.
getRange(): Promise<Range>;
Returns
Promise<Range> - marker position range
getType()
Returns whether this is a footnote or an endnote.
getType(): Promise<NoteType | null>;
Returns
Promise<NoteType | null> - footnote/endnote kind, null if none