Bojensen Blogs

Tag: MorphX

Playing with SSRS report in dynamics ax 2012

  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(); } How to save the SSRS report…

Ax 2012 Deploy reports through code « Shashi's Ax.Net Space

These lines deploys SSRS Reports with X++ Code – Remember not to run this code in CIL or you will get runtime error. SRSReportManager srsRptMgr = new SRSReportManager(); SSRSReportConceptNode node = new SSRSReportConceptNode(); node = TreeNode::findNode(@"SSRS ReportsReportsSalesInvoice"); srsRptMgr.deploymentStart(); srsRptMgr.deployReport(node); srsRptMgr.deploymentEnd();   Ax 2012 Deploy reports through code « Shashi’s Ax.Net Space

How to loop through a Map in AX 2012

  Map iim = new Map(Types::Integer, Types::Class); MapIterator it; // Add some elements into the map iim.insert(1, new query()); iim.insert(2, new query()); iim.insert(4, new query()); // Create a map iterator it = new MapIterator (iim); // Print "[int -> class] iterator" print it.definitionString(); // Go on for as long as elements are found in the…