Table of Contents

Method Read

Namespace
DocWright.MailMerge
Assembly
DocWright.MailMerge.dll

Read(Stream, string?, int)

Reads a sheet as a recipient list.

public static XlsxMergeData Read(Stream workbook, string? sheet = null, int maxRecords = 0)

Parameters

workbook Stream

The workbook (.xlsx).

sheet string

The sheet's name; null for the first sheet.

maxRecords int

The most records read; 0 for DefaultMaxRecords.

Returns

XlsxMergeData

The list.

Exceptions

ArgumentNullException

workbook is null.

ArgumentException

The workbook has no sheet of that name.

InvalidDataException

The stream is not a workbook this reader reads, or a part is too large.