IsEndnote
Check if the current document content is an endnote.
Syntax
expression.IsEndnote();
expression - A variable that represents a ApiDocumentContent class.
Parameters
This method doesn't have any parameters.
Returns
boolean
Example
This example check is the ApiDocumentContent is a endnote.
- Code
- Result
// How to add endnote to the document.
let doc = Api.GetDocument();
let endnote = doc.AddEndnote();
let paragraph = endnote.GetElement(0);
paragraph.AddText("Endnote text");
let isFootnote = endnote.IsFootnote();
let isEndnote = endnote.IsEndnote();
paragraph = Api.CreateParagraph();
doc.Push(paragraph);
paragraph.AddText("Footnote " + isFootnote);
paragraph.AddLineBreak();
paragraph.AddText("Endnote " + isEndnote);