PrxMdService.generateProblem

Syntax

generateProblem(report, callback);

Parameters

report. PP.Prx.Report. Report

callback. PP.Delegate. Callback function.

Description

The generateProblem method sends a query for modeling problem generation.

Comments

The method implements logic of pressing the Modeling and Forecasting button on the tool ribbon.

Example

To execute this example, the page must contain the ReportBox component named reportBox (see Example of the ReportBox Component Layout). The report should be based on a time series database.

// Get service and report
dv = reportBox.getDataView();
prxMdService = dv.getService();
report = reportBox.getSource();
// Set event handler that displays server response in the console
callback = function(sender, args) {
  console.log(args.Response);
};
// Send a query for modeling problem generation
prxMdService.generateWbk(report, callback);

After executing the example the browser console displays a JSON object containing server response for workbook generation.

See also:

PrxMdService