Thursday, July 12, 2012

Error Importing In Dynamics AX 2009

Implementations can be very stressful sometimes especially if the seemingly simplest of tasks seem to take you forever to get sorted. I had a junior consultant who ran into such a scenario in one of his implementations. Consider a case where you are taking on data, thousands of lines from your Excel, to your Dynamics AX 2009 application. After successfully importing the transactions but perhaps noticing you made some mistake in your import, you modify your Excel and try again and BANG........!!!



Dont worry!! This requires a small fix!


Step1: Select the definition group that you are trying to import and click Table Setup

Step2: Go to the 3rd column, Import status, and change from imported in total to import. Save and close the form


Step3: Click import on the Data import/export definition group form and click import

there you go, all data is imported


Happy Daxing My Friends!!!

Friday, July 6, 2012

Consuming currency web service in AX 2009

Im going to show you how to consume a web service in Dynamics AX. I had a requirement to consume currency exchange rates between my customer and a bank. however the bank did not have any available web service. So my B2B integration required me to create a web service at the bank end and then consume it again at my customer end. I will share with you how i consumed it in Dynamics AX2009.


In this demo we are going to do:


1) Create a service reference in AX2009

  • Go to  AOT > References > Right-Click Add New Service Reference.
Note WSDL URL should refer to your web service http address or in this case a free web service which is equally good.
The ExchRateWebService is the name of your reference.


2) Create an AX2009 class to consume the service

  • Next  AOT > Classes and create a new class

public class EtugExchRates 

{



}

  • add the following method to your class

3) Create a Job to test the code in AOT >Jobs
4) Go to General Ledger>Setup>Exchange Rates after running the job to see the result

Happy Dax++ng guys!!