Class Footnote
Represents the footnote in the word document.
Inheritance
System.Object
Footnote
Namespace: Syncfusion.DocIO.DLS
Assembly: Syncfusion.DocIO.Portable.dll
Syntax
public class Footnote : Object
Examples
The following code example demonstrates how to to change the default footnote separator.
private void Button1_Click(System.Object sender, System.EventArgs e)
{
//Create a new Word document
WordDocument document = new WordDocument();
//Create a section
IWSection section = document.AddSection();
//Add a paragraph to a section
IWParagraph paragraph = section.AddParagraph();
//Append the text to paragraph
paragraph.AppendText("Working with footnotes");
//Formatting the text
paragraph.ApplyStyle(BuiltinStyle.Heading1);
//Add a paragraph to a section
paragraph = section.AddParagraph();
//Append the footnotes
WFootnote footnote = (WFootnote)paragraph.AppendFootnote(Syncfusion.DocIO.FootnoteType.Footnote);
WTextBody separator = document.Footnotes.Separator;
//Replace the default foot note separate by text
separator.Paragraphs[0].Text = "Footnote separator";
//Set the footnote character format
footnote.MarkerCharacterFormat.SubSuperScript = SubSuperScript.SuperScript;
//Inserts the text into the paragraph
paragraph.AppendText("Sample content for footnotes").CharacterFormat.Bold = true;
//Add footnote text
paragraph = footnote.TextBody.AddParagraph();
paragraph.AppendText("Lorem ipsum dolor sit amet, lacus amet amet ultricies. Quisque mi venenatis morbi libero, orci dis, mi ut et class porta, massa ligula magna enim, aliquam orci vestibulum Turpis facilisis vitae consequat, cum a a,turpis dui consequat massa in dolor per, felis non amet.Auctor eleifend in omnis elit vestibulum, donec non elementum tellus est mauris, id aliquam, at lacus, arcu pretium proin lacus dolor et. Eu tortor, vel ultrices amet dignissim mauris vehicula");
//Save and close the Word document instance
document.Save("Sample.docx", FormatType.Docx);
document.Close();
}
Private Sub button_Click(sender As Object, e As EventArgs)
End Sub
Constructors
Footnote(WordDocument)
Initializes a new instance of the Footnote class.
Declaration
public Footnote(WordDocument document)
Parameters
Type | Name | Description |
---|---|---|
WordDocument | document | The WordDocument object. |
Properties
ContinuationNotice
Gets or sets the footnote continuation notice of the document.
Declaration
public WTextBody ContinuationNotice { get; set; }
Property Value
Type | Description |
---|---|
WTextBody | The WTextBody that represents the continuation notice. |
ContinuationSeparator
Gets or sets the footnote continuation separator of the document.
Declaration
public WTextBody ContinuationSeparator { get; set; }
Property Value
Type | Description |
---|---|
WTextBody | The WTextBody that represents the continuation separator. |
Separator
Gets or sets the footnote separator of the document.
Declaration
public WTextBody Separator { get; set; }
Property Value
Type | Description |
---|---|
WTextBody | The WTextBody that represents the separator. |
Methods
Clone()
Creates a duplicate copy of the current footnote.
Declaration
public Footnote Clone()
Returns
Type | Description |
---|---|
Footnote | The cloned Footnote object. |