Skip to main content

ReportDesignerPreviewClientSideEventsBuilder.CustomizeMenuActions(String) Method

Sets the name of the JavaScript function or the entire code that will handle the CustomizeMenuActions client-side event of the Web Report Designer‘s Preview.

Namespace: DevExpress.AspNetCore.Reporting.ReportDesigner

Assembly: DevExpress.AspNetCore.Reporting.v24.1.dll

NuGet Package: DevExpress.AspNetCore.Reporting

Declaration

public ReportDesignerPreviewClientSideEventsBuilder CustomizeMenuActions(
    string callback
)

Parameters

Name Type Description
callback String

The name of a JavaScript function or the entire JavaScript function code used to handle the CustomizeMenuActions event.

Returns

Type Description
ReportDesignerPreviewClientSideEventsBuilder

A ReportDesignerPreviewClientSideEventsBuilder that can be used to further configure the Report Designer Preview Client Side Events.

Remarks

The CustomizeMenuActions event enables you to customize the menu actions of the Document Viewer that is built into the Web Report Designer. When implementing a handling function, use the objects passed as parameters. The first parameter passes the event sender that is the ClientReportDesigner object. The second one is an object with the following structure.

  • Actions
    A collection of Actions available in the Web Report Designer’ Document Viewer toolbar and menu.

  • GetById
    This method allows you to obtain the required Action by its ID (ActionId value).

The following example demonstrates how to hide the existing Highlight Editing Fields toolbar command and add a new Run Slide Show command that navigates through document pages.

@{
    var designer = Html.DevExpress().ReportDesigner("reportDesigner1").Height("1000px")
        .Bind(Model.Report)
        .ClientSideEvents(configure => { configure.Preview(configure => { configure.CustomizeElements("customizeMenuActions"); }); } );
}
@designer

See the following topics for more information:

See Also