SBS Group Acquires Microsoft Dynamics® AX Practice from Solugenix Corporation

Friends,

SBS Group, a leading technology consulting firm integrating business management solutions, announced today the acquisition of Solugenix’s Microsoft Dynamics® AX Practice. Solugenix has a proven track record of successful implementations and support of Microsoft Dynamics AX across multiple industries. Solugenix will continue to provide Application Lifecycle Management, Enterprise Business Support and Professional Staffing solutions not related to Dynamics AX.

For more information: Click here.

Happy Dax6ng,

Sreenath Reddy

image

How to display/show the inventory dimensions as parameters on SSRS reports [Dynamics AX 2012, X++]

Friends,

Today, I am going to help you how to display the inventory dimensions [product dimensions, storage dimensions, Tracking dimensions] on SSRS reports as parameters. Not clear? Please see the Report parameters screen below.

All the inventory dimensions are available to be selected on report parameters below. You will see this view in almost all inventory reports and other module reports.

image

Well, Let me explain how to achieve this and retrieve the values in the data provider class

Its very simple, we need to make use of the contract class for this inventory dimensions view.

Standard has got a InventDimViewContract class with all the parm inventory dimensions methods and we can use these methods later in the DP classes for the selected inventory dimensions by the user on the report parameters screen.

Create an Object for InventDimViewContract in your contract class as shown below [Please note: I am using ProdPickListContract] as an example below

image

Then add a new parm method to the contract as shown below.

[DataMemberAttribute(‘InventDimViewContract’)]

public InventDimViewContract parmInventDimViewContract(InventDimViewContract _inventDimViewContract = inventDimViewContract)

{    

    inventDimViewContract = _inventDimViewContract;

    return inventDimViewContract;

}

That’s it, by adding the above discussed,we will get the inventory dimensions on the parameters screen.

Now, the question is how do we get the selected dimensions from the user. Its simple again.

In your data provider class, mainly in processReport method, get the object of the contract class and call the parmInventDimViewContract() method, this object will help you to retrieve the inventory dimensions selected by the user by using parm methods in it. [Example : ParmViewConfigId(), parmViewInventBatchId() etc]. Please refer to screen shot below.

image

You can use these selected inventory dimensions values based on your requirements. The above screen shot is just an example of retrieving the values.

 

Happy Dax6ng,

 

Sreenath Reddy

 

image

 

 

Upcoming: Microsoft Dynamics AX Solutions Excellence certification program that will help your company and employees show their level of AX expertise [H2 FY14]

Friends,

Microsoft Dynamics AX Solutions Excellence Certification Program has been designed to enable Microsoft Dynamics partners and individuals to achieve the highest level of certification on Microsoft Dynamics AX 2012. The Microsoft Dynamics AX Solutions Excellence Certification Program is aimed to help you:

  • Distinguish your partner organization and employees from the competition, and show your level of expertise to customers.
  • Demonstrate your company’s ability to provide proven, high-quality Microsoft Dynamics AX implementations.
  • Provide your employees with a learning path to attain the highest level of Microsoft Dynamics AX certification.
  • Provide your customers with best-in-class Microsoft Dynamics AX technical resources.

Beginning in H2 FY14, Microsoft Dynamics will be launching the exams for two out of the three AX Solutions Excellence Certification Program tracks, enabling Microsoft Dynamics partners and individuals to achieve the highest level of certification on Microsoft Dynamics AX 2012.

You can get more details from this link

Thank you!

Happy Dax6ng,

Sreenath Reddy

image

Cumulative update 6 (CU6) for Microsoft Dynamics AX 2012 R2

Friends, CU6 for Microsoft Dynamics AX 2012 R2 has been released. For more information, click here

Happy DAX6ng,

Sreenath

image

AX 2012 Cumulative Update 5[CU-5] has been released

Friends,

Cumulative Update 5 for Microsoft Dynamics AX 2012 (CU-5) has been released and published on Partner Source and Customer Source. Follow the below link

CU5 for AX 2012

This cumulative update includes all fixes that are described in Cumulative Update 4, Cumulative Update 3, Cumulative Update 2, and Cumulative Update 1 for Microsoft Dynamics AX 2012, country specific feature and additional hot fixes.

This cumulative update is applicable for both Microsoft Dynamics AX 2012 (6.0.947.0) & Microsoft Dynamics AX 2012 Feature Pack 1 (6.0.1108.0).

Happy Dax6ng,

Sreenath Reddy

Get the underlying SSRS Report Query, reset query , add your own ranges and execute report [Dynamics AX 2012, X++]

Friends,

Below is the small code snippet to get the underlying query of the SSRS report, reset query, prompt the parameters form, add our own ranges and execute the report. You can customize the job as per your requirements. Below I have used CustBaseData.Report report and added my own range on customer group.

static void SR_ResetQueries_executeReport(Args _args)

{

    #define.reportName(‘CustBaseData.Report’) // report Name

    QueryBuildRange queryBuildRange;

    QueryBuildDatasource queryBuildDatasource;

    SRSReportRun srsReportRun;

    Query reportRunQuery;

    srsReportRun = new SRSReportRun(#reportName);

    srsReportRun.init();

    srsReportRun.resetQueries(); // reset the query

    reportRunQuery = srsReportRun.reportQueries().lookup(srsReportRun.currentQueryKey());

    if (srsReportRun.isInitialized() && srsReportRun.prompt()) // prompt the parameters form

    {

        queryBuildDatasource = SysQuery::findOrCreateDataSource(reportRunQuery, tablenum(CustTable));

queryBuildRange = SysQuery::findOrCreateRange(queryBuildDatasource,  fieldnum(CustTable, CustGroup));

        queryBuildRange.value(‘INT’);

        queryBuildRange.status(RangeStatus::Hidden);

        srsReportRun.saveSettings();

        srsReportRun.executeReport();

    }

}

Happy Dax6ng,

Sreenath Reddy

 

Display SSRS report based on customer/Vendor specific language [Dynamics AX 2012]

Friends,

Common requirement is to show the reports in customer’s language [example : Quotations, sales confirmations, invoices, Free text invoices, Return order acknowledgements , Agreements,  Purchase order confirmations etc].

This was easily achievable in Dynamics AX 2009 reports by using

element.design().languageID(custConfirmJour.LanguageId); // language id

Well, how do I achieve the same thing  in AX 2012 SSRS Reports? image

Its simple , we still have one liner code only in AX 2012image

We need to use the controller classes, runPrintMgmt() method or preRunModifyContract() method which changes the contract class before report is run and am leaving this to you based on the requirements.

this.parmReportContract().parmRdlContract().parmLanguageId(custConfirmJour.Language);

Below is the screen shot for reference:image

image

Happy Dax6ng,

Sreenath Reddy

Sreenath Reddy

DialogEnumComboBox class in AX 2012 [X++, Restrict Enum elements in the dialog fields]

Friends,

It has been long time since I have posted. Clients always keeps us busy 🙂

Today’s post is very simple and quick way of restricting the Enum elements in the dialog fields in the dialogs.

We all know there are various ways of doing this in AX 2009, but in AX 2012, We have a new class which will help to easily achieve this through DialogEnumComboBox class.

As you see below, the sales status drop down will only show the Canceled and Invoiced elements though the enum has more elements in it.

image

Now, lets see how to do this. Create class and methods as shown below.

public class SR_TestDialogEnumComboBox extends RunBaseBatch

{

    DialogEnumComboBox  dialogEnumComboBox;

    DialogField         dialogType;

    DialogRunBase dialog;

    SalesStatus salesStatus;

 

    #define.FieldNoTmp(600)

}

public Object dialog()

{

    Set enumSet = new Set(Types::Enum);

    dialog = super();

 

    dialogType = new DialogField(dialog, enumStr(SalesStatus), #FieldNoTmp);   

    dialog.addCtrlDialogField(dialogType.name());

    dialogType.init(dialog);

    dialogType.label("Sales status");

    dialogType.helpText("Select sales status.");

    dialogType.value();

 

    enumSet.add(SalesStatus::Canceled);

    enumSet.add(SalesStatus::Invoiced);

 

dialogEnumComboBox = DialogEnumComboBox::newParameters(null, dialogType.control().id(), enumNum(SalesStatus), enumSet, dialog.form());

 

    return dialog;

}

public void dialogPostRun(DialogRunbase _dialog)

{

    super(_dialog);   

    _dialog.dialogForm().formRun().controlMethodOverload(true);

    _dialog.dialogForm().formRun().controlMethodOverloadObject(this);

    _dialog.formRun().controlMethodOverload(true);

    _dialog.formRun().controlMethodOverloadObject(this);

 

    if (dialogEnumComboBox)

    {

        // Specify the formRun (at this point the formRun is already available)

        // This is needed to track selection in the comboBox

        dialogEnumComboBox.parmFormRun(dialog.dialogForm().formRun());

 

        // Select a specific entry in the comboBox, if needed

        dialogEnumComboBox.select(SalesStatus::Invoiced);

 

    }

}

public boolean getFromDialog()

{

    boolean ret;

    ret = super();

 

    if (dialogEnumComboBox)

    {

        salesStatus = dialogEnumComboBox.selection();

    }

    return ret;

}

client server static ClassDescription description()

{

    return "DialogEnumComboBox example";

}

public static void main(Args _args)

{

    SR_TestDialogEnumComboBox testDialogComboBox = new SR_TestDialogEnumComboBox();

 

    if (testDialogComboBox.prompt())

    {

        testDialogComboBox.run();

    }

}

public void run()

{

    info(enum2str(salesStatus));

}

Happy Dax6ng,

Sreenath Reddy

image

Duplicate SSRS report Wizard– Performance improved {1-5 minutes now} [AX 2012]

Friends,

Thanks a lot for your feedback and responses on Duplicate SSRS report wizard tool for AX 2012.

I know that there was a concern on the performance of this wizard and was not having much time to improve it.

Thanks to Krasimir Kirilov for his feedback and modifications to improve the performance. I will be sending a copy of this tool to all of those who got a copy earlier.

Interested readers please contact me for a copy of the wizard

Thank you!

Sreenath

How to get the count of number of pages printed on to SSRS report [AX 2012 , X++]

Friends,

Recently, I came across an interesting requirement on the reports in AX 2012. If the total number of pages that gets rendered to the report is more than some X pages, the report should get saved to pdf, if not send it as an email.

Tricky part is how do I get the number of pages [page count] after the report got rendered. I tried to get the number of pages before rendering the report but was unsuccessful by using the adapter class and getNumberOfPages() method.

Finally, I found a solution. On Controller classes there is a method by name “reportViewerRefreshComplete” which can be overridden. This method gets triggered once the data has been rendered on to report viewer.

Override the “reportViewerRefreshComplete” method on any controller class and add the below code. This will help to get the count of printed physical pages on to report.

public void reportViewerRefreshComplete(SRSReportExecutionInfo _executionInfo)

{

    int page;

    super(_executionInfo);

 

    page = this.getReportContract().parmReportExecutionInfo().parmPrintedPhysicalPages();

    info("Total number of pages:" + int2str(page));

}

Below is the infolog with the counter of pages, after the report data got rendered on to report viewer.

image

Happy Dax6’ng.

Sreenath Reddy

sree