TX Text Control .NET for Windows Forms

FootnoteCollection Class

Class|Introduced in 32.0
Namespace
TXTextControl
Package
TXTextControl.TextControl.WinForms.SDK from the private NuGet feed or Text Control Offline Packages
Assembly
TXTextControl.dll
Install
dotnet add package TXTextControl.TextControl.WinForms.SDK .NET 8 and later. For .NET Framework, reference TXTextControl.dll from the setup.
Implements
ICollection, IEnumerable

Description

An instance of the FootnoteCollection class contains all footnotes in a Text Control document represented through objects of the type Footnote. An instance of this class can be obtained with the TextControl.Footnotes, WPF.TextControl.Footnotes and ServerTextControl.Footnotes property. The FootnoteCollection class implements the IEnumerable and the ICollection interfaces.

Syntax

public sealed class FootnoteCollection : ICollection, IEnumerable

Examples

The following example works with footnotes in the current document.

textControl.Text = "Customer: Contoso Ltd.";
textControl.Select(10, 12);
FootnoteCollection footnoteCollection = textControl.Footnotes;
footnoteCollection.Add(new Footnote("Source: FY 2026 annual report") { ID = 100 }, false);

Members

Properties

PropertyDescription
CountGets the number of elements contained in the collection.
HighlightModeGets or sets a value indicating whether all the footnote numbers, reference marks as well as footnote marks, in the document are highlighted.
ItemGets the footnote with the specified number from the collection. The number must be between 1 and Count. In C# this property is the indexer for the FootnoteCollection class.
NumberFormatGets or sets the footnotes' number format. The property's value is a member of the NumberFormat enumeration.
StartNumberGets or sets the number for the first footnote.

Methods

MethodDescription
AddAdds a new footnote to the document at the current text input position. A footnote consists of a reference mark in the document and the footnote itself appearing at the bottom of the page.
CopyToCopies the elements of the collection to an array, starting at a particular index.
GetEnumeratorReturns an enumerator that can be used to iterate through the collection.
GetItemGets a particular footnote from the collection.
RemoveRemoves a footnote from a Text Control document.