Skip to main content
.NET Framework 4.5.2+

ExportController.CustomExport Event

Occurs when executing the ExportController.ExportAction. Allows you to customize export options and/or implement a custom export.

Namespace: DevExpress.ExpressApp.SystemModule

Assembly: DevExpress.ExpressApp.v24.1.dll

NuGet Package: DevExpress.ExpressApp

Declaration

public event EventHandler<CustomExportEventArgs> CustomExport

Event Data

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

Property Description
ExportOptions Specifies the export options to be applied when data is exported.
ExportTarget Gets the format in which the exported data should be stored.
Handled Gets or sets a value that indicates whether the event handler has completely handled the event or whether the system should continue its own processing. Inherited from HandledEventArgs.
Printable Specifies the IPrintable control which is used by a List Editor to export data.
Stream Gets the stream to which the exported data should be stored.

Remarks

The CustomExport event occurs before export. The handler’s CustomExportEventArgs.ExportOptions parameter allows you to customize export options for the required export format. To get the target format in which the data is about to be exported, use the handler’s CustomExportEventArgs.ExportTarget parameter.

You can also customize the export options that are provided by the control to be exported. To access this control, use the CustomExportEventArgs.Printable event handler parameter. To learn how to change the control’s export settings, refer to the parameter’s description.

If you need to implement a custom export, use the CustomExportEventArgs.Stream and CustomExportEventArgs.Printable parameters. In addition, if you don’t need the default export operation to be performed, set the handler’s Handled parameter to true.

Refer to the How to: Customize the Export Action Behavior topic, to see an example of handling this event.

See Also