Back to Devexpress

SpreadsheetMailMergeOptions.UseTemplateSheetNames Property

officefileapi-devexpress-dot-spreadsheet-dot-spreadsheetmailmergeoptions.md

latest2.7 KB
Original Source

SpreadsheetMailMergeOptions.UseTemplateSheetNames Property

Gets or sets a value indicating whether worksheet names in a merged document(s) should be generated based on the template worksheet’s name.

Namespace : DevExpress.Spreadsheet

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

NuGet Package : DevExpress.Spreadsheet.Core

Declaration

csharp
bool UseTemplateSheetNames { get; set; }
vb
Property UseTemplateSheetNames As Boolean

Property Value

TypeDescription
Boolean

true , to use the template worksheet’s name to name worksheets in the resulting document(s); otherwise, false.

|

Property Paths

You can access this nested property as listed below:

Object TypePath to UseTemplateSheetNames
IWorkbook

.MailMergeOptions .UseTemplateSheetNames

| | Workbook |

.MailMergeOptions .UseTemplateSheetNames

|

Remarks

The following table demonstrates how the UseTemplateSheetNames property works depending on the selected mail merge mode (it is assumed that the template worksheet’s name is set to TemplateSheet).

|

Mail Merge Mode

|

UseTemplateSheetNames = False

(Default)

|

UseTemplateSheetNames = True

| | --- | --- | --- | |

Multiple Documents

|

The resulting worksheet name for each workbook is Sheet1.

|

The resulting worksheet name for each workbook is TemplateSheet.

| |

Multiple Worksheets

|

The resulting worksheet names are Sheet1, Sheet2, …, SheetN.

|

The resulting worksheet names are TemplateSheet1, TemplateSheet2, …, TemplateSheetN.

| |

Single Worksheet

|

The resulting worksheet name is Sheet1.

|

The resulting worksheet name is TemplateSheet.

|

See Also

SpreadsheetMailMergeOptions Interface

SpreadsheetMailMergeOptions Members

DevExpress.Spreadsheet Namespace