openReport (key: Integer, params: Array, interactive: Boolean, callback: PP.Delegate);
key. Key of the report to be opened.
params. Array of parameters to be applied on opening the report.
interactive. Determines if the dialog box for entering parameters' values opens on calling the method. If this parameter is set to True (default), the dialog box opens, otherwise it does not.
callback. Callback procedure.
The openReport method opens a regular report with some parameters.
To execute this example, the HTML page must contain the ReportBox component named reportBox and the service used to work with a regular report named prxMbService (see Example of the ReportBox Component Layout). The repository must contain a regular report with the key 1023, that has some defined parameters. Open a regular report, and show the parameters setup dialog box before the report opens:
//get report source
report = reportBox.getSource();
//get parameters array
params = report.getParams();
//open report with parameters
prxMdService.openReport(1023, params, true);
Executing this example opens the report with the specified key and displays a dialog box where the user can enter parameters' values.
NOTE. Dialog box for entering parameter values is not shown if all the parameters are set to their default values.
See also: