Skip to main content

DxDocumentViewerCallbacks.CustomizeExportOptions Property

Specifies the handler for the CustomizeExportOptions client-side event that allows you hide export formats and specify the default export options.

Namespace: DevExpress.Blazor.Reporting

Assembly: DevExpress.Blazor.Reporting.v24.1.JSBasedControls.Common.dll

NuGet Package: DevExpress.Blazor.Reporting.JSBasedControls.Common


public string CustomizeExportOptions { get; set; }

Property Value

Type Description

The name of a JavaScript function used to handle the CustomizeExportOptions event.


The CustomizeExportOptions event allows you to hide export formats and specify the default export options in the Web Document Viewer.

The handler function receives two parameters - the first parameter is the client-side Document Viewer (the event sender) that exposes the dx property to access the client-side DevExpress objects. The second parameter is an object with the following properties and methods:

  • HideExportOptionsPanel method
    Hides the Export Options panel.

  • HideFormat method
    Hides the specified export format from the Export To drop-down list and also hides its related category from the Export Options panel.

  • HideProperties method
    Hides the specified options for the export format in the Export Options panel. To remove all options for a particular export format, specify only the first method parameter.

  • GetExportOptionsModel method
    Returns the export options model for the specified export format. Use this model to change the option’s default value.

The code sample below does the following:

  • removes the CSV format from the list of available export formats and from the Options tab;
  • removes the TXT format from the list of available export formats and from the Options tab;
  • hides the “ExportMode” and “PageRange” options for the XLS format;
  • removes the RTF section from the Options tab;
  • specifies “false” as the ExportHyperlinks option’s default value for XLS export.
window.ReportingViewerCustomization = {
    onCustomizeExportOptions: function (s, e) {
        // Remove CSV export.
        // Remove Text export
        e.HideFormat({ format: s.dx.Reporting.Viewer.ExportFormatID.TXT, propertyName: "textExportOptions" });
        // Do not show the ExportMode and PageRange property editors in the XLSX Export Options section. 
        e.HideProperties(s.dx.Reporting.Viewer.ExportFormatID.XLSX, "ExportMode", "PageRange");
        // Hide the RTF Export Options section.
        // Clear the Export Hyperlinks checkbox in the XLS Export Options section.
        var model = e.GetExportOptionsModel(s.dx.Reporting.Viewer.ExportFormatID.XLS);
        model.exportHyperlinks = false
See Also