MailMergeSettingsBuilder.DataSource(IEnumerable) Method

Sets a data source for Rich Text Editor's mail merge functionality.

Namespace: DevExpress.AspNetCore.RichEdit

Assembly: DevExpress.AspNetCore.RichEdit.v20.1.dll

Declaration

public MailMergeSettingsBuilder DataSource(
    IEnumerable data
)

Parameters

Name Type Description
data IEnumerable

The MailMerge data source.

Returns

Type Description
MailMergeSettingsBuilder

An object that can be used to further configure the MailMerge settings.

Remarks

For a full example, see the Rich Text Editor - Mail Merge demo.

@(Html.DevExpress().RichEdit("DemoRichEdit")
    .Open("Documents/MailMergeTemplate.docx")
    .MailMerge(m => m
        .DataSource(SampleData.Companies)
        .ViewMergedData(true)
        .ActiveRecord(0)
    )
)
See Also