Aspose.Pdf

How to Create FootNotes

Indicate notes in the text of your paper by using consecutive superscript numbers. The actual note is indented and can occur as a footnote at the bottom of the page. In a footnote referencing system, indicate a reference by:

 

 

 

The Structure of the FootNote is shown in the diagram below:

 

 

Please follow the following steps to create a FootNote:

 

 

The following example demonstrates how to add Footnotes to the bottom of the Pdf page.

 

Code Snippet

 

[C#]

 

Pdf pdf = new Pdf();

 

//Create Section

Section sec = pdf.Sections.Add();

 

//Create Text Paragraph

Text text = new Text();                               

 

//Create Segment

Segment segment = new Segment("This is the First Segment");

 

//Create FootNote and Assign FootNote property of Segment to its object

segment.FootNote = new FootNote("Footnotes for First Segment");

 

//Add Segment in Text Paragraph

text.Segments.Add(segment);

 

 

//Add Text in Section

sec.Paragraphs.Add(text);

 

 

//Save the Pdf

pdf.Save("D:/AsposeTest/FootNotedemo.pdf");

 

 

[VB.NET]

 

Dim pdf As Pdf = New Pdf

 

'Create Section

Dim sec As Section = pdf.Sections.Add

 

'Create Text Paragraph

Dim text As Text = New Text

 

'Create Segment

Dim segment As Segment = New Segment("This is the First Segment")

 

'Create FootNote and Assign FootNote property of Segment to its object

segment.FootNote = New FootNote("Footnotes for First Segment")

 

'Add Segment in Text Paragraph

text.Segments.Add(segment)

 

'Add Text in Section

sec.Paragraphs.Add(text)

 

'Save the Pdf

pdf.Save("D:/AsposeTest/FootNotedemo.pdf")

 

To create FootNotes using the XML. Please check the following:

 

[XML]

 

   <Section PageWidth="595.3" PageHeight="841.9" PageMarginTop="72" PageMarginBottom="72" PageMarginLeft="90" PageMarginRight="90" IsNewPage="true">

    <Text IsSpaced="true" Alignment="Justify" LineSpacing="1.58" ID="paraId_1">

      <Segment FontName="Times New Roman">this is the first segment</Segment>

      <Segment>

              <FootNote>

                      <Segment>note for first</Segment>

              </FootNote>

      </Segment>

      <Segment FontName="Times New Roman">this is the second segment</Segment>

      <Segment FontName="Times New Roman">this is the third segment</Segment>

      <Segment>

              <FootNote>

                      <Segment>note for third</Segment>

              </FootNote>

      </Segment>    

    </Text>

  </Section>

 

To get further details about FootNotes please visit our online API documents.