Consuming a Dynamics 365 for Operations SOAP service
In this recipe, we will create a new C# project to consume the service created in the previous recipe.
Before we start, we should understand the Azure AD authentication concepts explained in the Reading, writing, and updating data through OData recipe, in Chapter 8, Data Management, Odata, and Office. Many of the concepts in the following recipes extended the concepts we covered in this chapter.
In this example, we will create a SOAP service reference.
Getting ready
We are continuing the Creating a service recipe, which must be completed and built before we continue.
How to do it...
To consume a Dynamics 365 for Operations service using SOAP, follow these steps:
- Create a new project; this time, choose
Visual C#
from theTemplates
node and thenConsole Application
from the right. Name the projectConServiceTest
and place it in the project folders that we set up for source control. Ensure that the namespace is alsoConServiceTest
. - We will now need...