Calling methods on a caller form

This is actually something small but it comes in handy from time to time ! Due to the poor design on some form I have to make changes to, I needed this thing here. I replaced a button on the form with code behind it (yes, business logic behind a button is a BAD practice […] Read More...
Posted in Dynamics Ax.

Inside SalesFormLetter class : ReArrange

Many times before I have made changes to the salesFormLetter classes and every time I went in there I was afraid ( as a figure of speech ) of the reArrange method. The whole thing was clear to me from a functional point of view, but the technical side of it was another pair of […] Read More...
Posted in Dynamics Ax.

Debugging AIF on Windows 2008

For those who are using Windows 2008 as server platform and want to debug the Dynamics 2009 AIF… this will help! We are using AIF WCF web services to communicate between a .NET portal and Dynamics Ax. And while developing we were unable to debug the code running in the Business Connector. Since we were […] Read More...
Posted in Dynamics Ax.

Moving objects between layers

Today I am working at a customer site and today’s task is to move all objects from the USR layer to the VAR layer. (Don’t ask why but due to licensing we could not work in the VAR layer) There is already data present, so we cannot just move the objects without further attention.           There […] Read More...
Posted in Dynamics Ax.

Header2Line functionality : Adding an extra field

It is possible to update fields on the purchase lines when the according field on the purchase header record changes. When you want to add a field to this functionality, this is what you need to do to make it work :  Add the field to the Header2LineUpdate field group   Add field in the […] Read More...
Posted in Dynamics Ax.

Dynamics AIF : Query Update Stacktrace

Today, when updating some records through AIF I got the following error : This is definitely not a clear error since the only thing was wrong is that the Update property was set to No instead of Yes on the Query’s datasource. Thanks to a collegue of mine (from artofcreation) to point this one out […] Read More...
Posted in Dynamics Ax.

Dynamics AIF : Null vs Empty string

Today I experienced that when using AIF through web services, you have to pay attention to the difference between an empty string and a null value. We created a service for inventory locations and we had the InventLocationId filled in by the AIF. But when calling the service we received an error everytime telling us […] Read More...
Posted in Dynamics Ax.

Dynamics AIF : Working Times service

Today I created an AIF web service to expose the Working times functionality in Ax 2009. The service itself is quite simple but there was the issue with the workTimeId. The application on the other side doesn’t care about the Id of the working times and wants Dynamics to use a number sequence for the […] Read More...
Posted in Dynamics Ax.

Dynamics AIF : Tracing Web Service calls

When using AIF through web services, you can be in the dark when you want to know what’s really going on in there. Additionally you can have trouble debugging the thing when you are running a Windows 2008 box. (Contacted Microsoft last week and the response was that debuggin AIF webservices does not work on […] Read More...
Posted in Dynamics Ax.

Dynamics AIF : Invalid child element in namespace

A couple of days ago, I encountered this problem while calling the InventInventLocation AIF web service’s create operation. System.ServiceModel.FaultException : Invalid document schema. The following error is reported : The element ‘InventLocation’ in namespace ‘http://schemas.microsoft.com/dynamics/2008/01/documents/InventLocation’ has invalid child element ‘InventLocationIdQuarantine’ in namespace ‘http://schemas.microsoft.com/dynamics/2008/01/documents/InventLocation’. List of possible elements expected: ‘InventLocationId’ in namespace ‘http://schemas.microsoft.com/dynamics/2008/01/documents/InventLocation’.  The error itself […] Read More...
Posted in Dynamics Ax.