Tuesday, August 11, 2015

How to print the SSRS report in dynamics ax 2012 from code.

SrsReportRun srsReportRun; // initiate the report. 
srsReportRun = new SrsReportRun ("InventTruckTransactionReport.PrecisionDesign1"); 
srsReportRun.init(); 
srsReportRun.reportCaption("InventTruckTransactionReport.PrecisionDesign1"); // set parameters name, value. 
srsReportRun.reportParameter("TruckTransDS_JournalId").value("000161_070"); // suppress the dialog 
srsReportRun.showDialog(false); 
if( srsReportRun ) 
{ // run the report 
       srsReportRun.executeReport(); 
}

No comments:

Post a Comment