Back to Devexpress

MailMergeOptions.FirstRecordIndex Property

officefileapi-devexpress-dot-xtrarichedit-dot-api-dot-native-dot-mailmergeoptions-0cc97ca3.md

latest3.6 KB
Original Source

MailMergeOptions.FirstRecordIndex Property

Gets or sets the record index from which the merge starts.

Namespace : DevExpress.XtraRichEdit.API.Native

Assembly : DevExpress.RichEdit.v25.2.Core.dll

NuGet Package : DevExpress.RichEdit.Core

Declaration

csharp
int FirstRecordIndex { get; set; }
vb
Property FirstRecordIndex As Integer

Property Value

TypeDescription
Int32

The starting record index (starting with 0 ).

|

The following code snippets (auto-collected from DevExpress Examples) contain references to the FirstRecordIndex property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-richedit-control-mail-merge/CS/MailMerge/Form1.cs#L27

csharp
MailMergeOptions myMergeOptions = richEditControl1.Document.CreateMailMergeOptions();
myMergeOptions.FirstRecordIndex = 1;
myMergeOptions.LastRecordIndex = 3;

winforms-richedit-use-images-in-mail-merge/CS/Form1.cs#L53

csharp
if (form.MergeRecords == MergeRecords.FromInterval) {
    options.FirstRecordIndex = Math.Max(0, ((MergeSimpleDataForm)form).StartIndex - 1);
    options.LastRecordIndex = Math.Min(NorthwindDataProvider.Categories.Rows.Count - 1, ((MergeSimpleDataForm)form).EndIndex - 1);

winforms-richedit-control-mail-merge/VB/MailMerge/Form1.vb#L24

vb
Dim myMergeOptions As MailMergeOptions = richEditControl1.Document.CreateMailMergeOptions()
myMergeOptions.FirstRecordIndex = 1
myMergeOptions.LastRecordIndex = 3

winforms-richedit-use-images-in-mail-merge/VB/Form1.vb#L53

vb
If form.MergeRecords = MergeRecords.FromInterval Then
    options.FirstRecordIndex = Math.Max(0, CType(form, MergeSimpleDataForm).StartIndex - 1)
    options.LastRecordIndex = Math.Min(Categories.Rows.Count - 1, CType(form, MergeSimpleDataForm).EndIndex - 1)

See Also

LastRecordIndex

MailMerge

MailMergeOptions Interface

MailMergeOptions Members

DevExpress.XtraRichEdit.API.Native Namespace