Modifying a report query based on the input data in AX 2012R3 | CloudFronts

Modifying a report query based on the input data in AX 2012R3


Controller class is used to control the report execution as well as pre processing of the report data. The SSRS reporting framework uses this class to modify the report dialog, calling the SQL Server reporting services, as well pre processing parameters for the report.

How to do?

  1. Create a new class. Open AOT –> Classes
  2. Open the class declaration and select on View Code
  3. Now write the following code:
    class SSRSDemoController extends SrsReportRunController
  4. Create a new method and write the following code:
    public static client void main(Args args)
    //define the new object for controller class
    SSRSDemoController ssrsDemoController;
    ssrsDemoController = new SSRSDemoController();
    //pass the caller args to the controller
    //set the report name and report design to run
    //execute the report


Reports that are opened from a form – Controller class is also used when reports are opened fro a form and are needed to show selected records details. Use preRunModifyContract method to achieve this.

Share Story :

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.