All docs
V21.1
21.2 (EAP/Beta)
21.1
20.2
20.1
19.2
The page you are viewing does not exist in version 19.2. This link will take you to the root page.
19.1
The page you are viewing does not exist in version 19.1. This link will take you to the root page.
18.2
The page you are viewing does not exist in version 18.2. This link will take you to the root page.
18.1
The page you are viewing does not exist in version 18.1. This link will take you to the root page.
17.2
The page you are viewing does not exist in version 17.2. This link will take you to the root page.
.NET Framework 4.5.2+
.NET Framework 4.5.2+
.NET Standard 2.0+

NoteCollection.Insert(DocumentPosition, String) Method

Inserts a new note into the specific document position with a custom mark.

Namespace: DevExpress.XtraRichEdit.API.Native

Assembly: DevExpress.RichEdit.v21.1.Core.dll

Declaration

Note Insert(
    DocumentPosition position,
    string customMark
)

Parameters

Name Type Description
position DocumentPosition

A document position to insert a reference into.

customMark String

A format string for the symbol used to mark the reference.

Returns

Type Description
Note

A note (footnote or endnote).

Remarks

A custom reference mark representation depends on the font applied to the reference range.

The code sample below shows how to insert a footnote and an endnote with a custom mark:

RichEditDocumentServer wordProcessor = new RichEditDocumentServer();
wordProcessor.LoadDocument("Document.docx");
Document document = wordProcessor.Document;

//Insert a footnote with a ` custom mark:
DocumentPosition footnoteWithCustomMarkPosition = document.CreatePosition(document.Paragraphs[7].Range.End.ToInt() - 1);
document.Footnotes.Insert(footnoteWithCustomMarkPosition, "\u00BA");

//Insert an endnote with a º custom mark:
DocumentPosition endnoteWithCustomMarkPosition = document.CreatePosition(document.Paragraphs[document.Paragraphs.Count - 2].Range.End.ToInt() - 1);
document.Endnotes.Insert(endnoteWithCustomMarkPosition, "\u0060");
See Also