RibbonView.Opened

Syntax

Opened: function (sender, args)

Parameters

sender. Event source.

args. Event information.

Description

The Opened event is fired on selecting the Open item in main menu of the regular report.

Example

Executing this example requires the following: create a service for working with regular reports ( prxMbService) on the HTML page, connect to the metabase and open the regular report named prxReport (see Example of the ReportBox Component Layout). The root folder of the application must contain the PP_Img folder containing icons. Create a ReportBox component, and add an even handler, that handles selection of the Open item in the main menu, for the tool ribbon:

    var reportBox = new PP.Prx.Ui.ReportBox({
        ParentNode: "ReportBox",
        Source: prxReport,
        Service: prxMbService,
        ImagePath: "/PP_img/",
        RibbonView: {
            Opened: function () {
                if (!window.prxOpenDialog)
                    window.prxOpenDialog = new PP.Ui.MetabaseOpenDialog({//create dialog box to open a repository report
                        Metabase: metabase,
                        ImagePath: imgPath,
                        FiltersSet: [{
                            Filters: [PP.Mb.MetabaseObjectClass.KE_CLASS_PROCEDURALREPORT],
                            ResourceKey: "openDialogReports",
                            iconIndex: 16
                        }],
                        FolderTreeFilter: [PP.Mb.MetabaseObjectClass.KE_CLASS_FOLDER, PP.Mb.MetabaseObjectClass.KE_CLASS_WEBAPPLICATION]
                    });
                window.prxOpenDialog.show();
            }
        }
    });

Executing this example creates a ReportBox component. Selecting the Open item in the main menu opens the dialog box for opening repository object.

See also:

RibbonView