Skip to main content
Tab

ASPxGridViewDetailSettings.ExportMode Property

Specifies detail rows that can be exported.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v24.2.dll

NuGet Package: DevExpress.Web

#Declaration

[DefaultValue(GridViewDetailExportMode.None)]
public GridViewDetailExportMode ExportMode { get; set; }

#Property Value

Type Default Description
GridViewDetailExportMode None

Detail rows that can be exported.

Available values:

Name Description
None

Details are not exported.

Expanded

Only expanded details are exported.

All

All master and detail rows are exported regardless of their expanded state.

#Property Paths

You can access this nested property as listed below:

Object Type Path to ExportMode
ASPxGridView
.SettingsDetail .ExportMode
GridViewProperties
.SettingsDetail .ExportMode

#Remarks

The Grid control supports master-detail grid export in WYSIWYG mode only. Set the SettingsDetail.ExportMode property to Expanded or All to export detail grid records.

Run Demo: Export Master-Detail Records

<dx:ASPxGridView ID="grid" runat="server" DataSourceID="CategoriesDataSource" KeyFieldName="CategoryID">
    <Toolbars>
        <dx:GridViewToolbar>
            <Items>
                <dx:GridViewToolbarItem Command="ExportToPdf" />
                <dx:GridViewToolbarItem Command="ExportToXls" />
                <dx:GridViewToolbarItem Command="ExportToXlsx" />
            </Items>
        </dx:GridViewToolbar>
    </Toolbars>
    <SettingsDetail ShowDetailRow="true" ExportMode="All" />
    <SettingsExport EnableClientSideExportAPI="true" ExcelExportMode="WYSIWYG" />
    <Templates>
        <DetailRow>
            <dx:ASPxGridView ID="detailGrid" runat="server" DataSourceID="ProductsDataSource"
                KeyFieldName="ProductID" OnBeforePerformDataSelect="detailGrid_BeforePerformDataSelect" />
        </DetailRow>
    </Templates>
</dx:ASPxGridView>
See Also