O'Reilly logo

Microsoft Dynamics AX 2012 Services by Kenny Saelen, Klaas Deforche

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Consuming the service

Now that we have created and exposed our custom services, they are ready to be consumed. To do this, we use Visual Studio and write two code samples.

Example 1 – Retrieving titles

This first example of consuming the service deals with the retrieval of a title list. We want to be able to write a list of titles to the console window.

Adding the service reference

To add the service reference, perform the following steps:

  1. In Visual Studio, create a console application.
  2. Right-click on the Service References node and select the Add Service Reference… button. The Add Service Reference window opens.
  3. In the Address drop-down box, specify http://DYNAX01:8101/DynamicsAx/Services/CVRCustomServices as the address for the service and then press ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required