Class CreatingOptions
Options for creating new WorkBook object.
Inheritance
Namespace: IronXL.Options
Assembly: IronXL.dll
Syntax
public class CreatingOptions : Object
CreatingOptions is the small settings object that decides the file format of a brand-new IronXL WorkBook. It carries the choice between the legacy XLS format and the modern XLSX format, so a developer creating a spreadsheet from scratch can pin the output to whichever a downstream consumer expects rather than accepting the default.
Pass an instance when creating a workbook, having set its one property first. DefaultFileFormat is an ExcelFileFormat value, and XLSX is the default when nothing is specified, which suits most new files. Reach for XLS only when an older tool or process cannot read the newer format. Because the object holds a single decision, configuring it is a one-line step taken before the workbook exists; the chosen format then governs how that workbook saves unless overridden at save time. A parameterless constructor creates the options with the XLSX default already in place.
using IronXL;
using IronXL.Options;
var options = new CreatingOptions();
options.DefaultFileFormat = ExcelFileFormat.XLSX;The create a spreadsheet how-to walks through making a new workbook, and the create Excel spreadsheet example shows a worked file.
Constructors
CreatingOptions()
Declaration
public CreatingOptions()
Properties
DefaultFileFormat
Property that indicates whether to use XLS or XLSX as new workbook format.
XLSX is the default value for new workbook
Declaration
public ExcelFileFormat DefaultFileFormat { get; set; }
Property Value
| Type | Description |
|---|---|
| ExcelFileFormat | The default spreadsheet file format. |