Skip to main content

XlsxExportOptionsEx.LayoutMode Property

Gets or sets whether data is exported in regular mode or as a native Excel table.Only available in data-aware export mode.

Namespace: DevExpress.XtraPrinting

Assembly: DevExpress.Printing.v23.1.Core.dll

NuGet Packages: DevExpress.Printing.Core, DevExpress.Win.Dashboard.Design


public LayoutMode LayoutMode { get; set; }

Property Value

Type Description

A value that specifies whether data is exported in regular mode or as a native Excel table. The default value is Standard.


The LayoutMode property allows you to choose between exporting data in regular mode and as a native Excel table. The property can be set to one of the following values:


The following example shows how to change the style of the native Excel table to which data is exported from a grid control.

Data-aware Export to native Table-example.png

using DevExpress.Export.Xl;
using DevExpress.XtraPrinting;

string path = "gridNative.xlsx";
XlsxExportOptionsEx options = new XlsxExportOptionsEx();
options.LayoutMode = DevExpress.Export.LayoutMode.Table;
options.BeforeExportTable += ea => {
    ea.Table.Style.Name = XlBuiltInTableStyleId.Medium1;
gridControl1.ExportToXlsx(path, options);
See Also