Skip to main content
A newer version of this page is available. .

GridControl.ExportToXlsx(Stream, XlsxExportOptions) Method

Exports the data the GridControl.DefaultView (GridControl.MainView or the currently maximized detail View) displays to the specified stream in XLSX format using the specified options.

Namespace: DevExpress.XtraGrid

Assembly: DevExpress.XtraGrid.v19.1.dll

Declaration

public void ExportToXlsx(
    Stream stream,
    XlsxExportOptions options
)

Parameters

Name Type Description
stream Stream

A Stream object to which data is exported.

options XlsxExportOptions

An object that specifies export customization options and events. In data-aware export mode, initialize the parameter with a XlsxExportOptionsEx object. In WYSIWYG export mode, initialize the parameter with a XlsxExportOptions object.

Remarks

See Export to XLS and XLSX Formats to learn more.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the ExportToXlsx(Stream, XlsxExportOptions) method.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also