Philippsen's Blog

Everyday findings in my world of .net and related stuff

Posts Tagged ‘Service references’

Problem regenerating a Dynamics AX service reference

Posted by Torben M. Philippsen on November 11, 2011

When working with service references in Dynamics AX I often experience problems when trying to regenerate the service reference – for instance when the service definition has changed. The actual regeneration process succeeds, but when consuming the service reference new methods which I know was added (I can see them, when browsing the wsdl) are missing.

To workaround this issue the following has become the solution for me:

  • Go to the application folder. The application folder can be found in the “microsoft Dynamics AX server configuration utility”

    applicationfolder configuration

    applicationfolder configuration

  • Within the application folder – open the “Service references” folder.
  • Delete the folder with the same name as your service reference

For each AOS in your setup – do the following:

  • Stop the AOS service
  • Go to the folder “Dynamics AX” of the user running the AOS service. This could look something like this: C:\Users\sa-dynax\AppData\Local\Microsoft\Dynamics Ax, where “sa-dynax” is the user running the AOS service.
  • For each AOS you will have an instance folder.

    AOS instace folders

    AOS instace folders

  • Make sure only to apply changes to instances in the desired setup – eg. the testenvironment

    Active AOS instance

    Active AOS instance

  • In this case we can see that only the instance “01” is active and running.
  • in this case we are entering the folder “C:\Users\sa-dynax\AppData\Local\Microsoft\Dynamics Ax1” – since “01” is the active instance.
  • Enter the “ServiceReferences” folder.
  • Locate the folder with the same name as your ServiceReference in the Dynamics Ax AOT.
  • Delete the folder
  • Start the AOS service.

When the AOS service is starting, all service references from the application folder will be replicated to each AOS.
Sometimes this fails – and therfore causing the problem above.


Posted in Microsoft Dynamics AX | Tagged: , , | Comments Off on Problem regenerating a Dynamics AX service reference

%d bloggers like this: