Back to Devexpress

ASPxDashboard.CustomizeExportDocument Event

dashboard-devexpress-dot-dashboardweb-dot-aspxdashboard-e2a54e15.md

latest5.4 KB
Original Source

ASPxDashboard.CustomizeExportDocument Event

Allows you to customize the stream containing the resulting document (such as PDF, Image, or Excel).

Namespace : DevExpress.DashboardWeb

Assembly : DevExpress.Dashboard.v25.2.Web.WebForms.dll

NuGet Package : DevExpress.Web.Dashboard

Declaration

csharp
public event CustomizeExportDocumentWebEventHandler CustomizeExportDocument
vb
Public Event CustomizeExportDocument As CustomizeExportDocumentWebEventHandler

Event Data

The CustomizeExportDocument event's data class is CustomizeExportDocumentWebEventArgs. The following properties provide information specific to this event:

PropertyDescription
DashboardIdGets the identifier of the exported dashboard. Inherited from CustomExportBaseWebEventArgs.
ExcelExportOptionsGets options related to exporting a dashboard/dashboard item to Excel format.
ExcelOptionsObsolete. Gets options related to exporting a dashboard item to Excel format.
ExportActionGets the export action performed by an end-user. Inherited from CustomExportBaseWebEventArgs.
ExportModeGets the document export mode. Inherited from CustomExportBaseWebEventArgs.
ImageExportOptionsGets export options related to exporting a dashboard/dashboard item as an image. Inherited from CustomExportBaseWebEventArgs.
ImageOptionsObsolete. Gets export options related to exporting a dashboard/dashboard item as an image. Inherited from CustomExportBaseWebEventArgs.
ItemComponentNameGets the component name of the exported dashboard item. Inherited from CustomExportBaseWebEventArgs.
PdfExportOptionsGets export options related to exporting a dashboard/dashboard item to PDF format. Inherited from CustomExportBaseWebEventArgs.
PdfOptionsObsolete. Gets export options related to exporting a dashboard/dashboard item to PDF format. Inherited from CustomExportBaseWebEventArgs.
StreamGets or sets a stream containing the exported document.

The event data class exposes the following methods:

MethodDescription
GetDashboardItem(String)Returns a dashboard item that corresponds the specified component name.
GetItemData(String)Returns multidimensional data for the specified dashboard item.

Remarks

CustomizeExportDocument is raised after the ASPxDashboard.CustomExport and allows you to customize the stream containing the resulting document (such as PDF, Image or Excel). Use the CustomizeExportDocumentWebEventArgs.Stream event parameter to access the stream.

The following example shows how to add a custom header to each sheet for the exported workbook:

View Example

For more information about export, see the following topic: Exporting in the Web Dashboard.

See Also

CustomExport

ASPxDashboard Class

ASPxDashboard Members

DevExpress.DashboardWeb Namespace