XlsExportOptionsEx.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.v24.2.Core.dll
Declaration
Property Value
Type | Description |
---|---|
DevExpress.Export.LayoutMode | A value that specifies whether data is exported in regular mode or as a native Excel table. The default value is Standard. |
Remarks
For more information, see XlsxExportOptionsEx.LayoutMode.
Example
The following example shows how to change the style of the native Excel table to which data is exported from a grid control.
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