NAV2009: How to register a Webservice

Consuming Web Services using C# and Visual Studio 2005

Hallo zusammen! Hier ein Auszug aus unserem englischen Buch (NAV 2009 Inside) :

The following steps show how to create a simple windows forms application in Visual Studio to consume a Web service. These steps start with creating a new project in Visual Studio and then adding a Web Reference for the Web services published from Microsoft Dynamics NAV.

1. Open Visual Studio

2. Click File > New, and then click Project. The New Project window opens.

3. Expand the Visual C# node, and select Windows Forms Application.

4. Choose a name for the project

5. Click OK. The project initiates with default files and references.

6. In the Solution Explorer, right-click the References node in the project, and then click Add Web Reference. The Add Web Reference window opens.

7. Type the following in the URL bar:
http://localhost:7047/DynamicsNAV/WS/CRONUS_International_Ltd/Services

8. Click GO. The available services are displayed.

clip_image001

1. Click View Service for the service you want to add and then click Add Reference.

 

Consuming Web Services using C# and Visual Studio 2008

The following steps show how to create a simple windows forms application in Visual Studio to consume a Web service. These steps start with creating a new project in Visual Studio and then adding a Web Reference for the Web services published from Microsoft Dynamics NAV.

1. Open Visual Studio

2. Click File > New, and then click Project. The New Project window opens.

3. Expand the Visual C# node, and select Windows Forms Application.

4. Choose a project name

5. Click OK. The project initiates with default files and references.

6. In the Solution Explorer, right-click the References node in the project, and then click Add Service Reference. The Add Service Reference window opens.

clip_image002

1. Click on button “Advanced” at the left bottom of the Window. The following window opens:

clip_image003

1. Click on button “Add Web Reference…”. The Add Web Refences Window opens.

2. Type the following in the URL bar:
http://localhost:7047/DynamicsNAV/WS/CRONUS_International_Ltd/Services

3. Click GO. The available services are displayed.

clip_image004

1. Click View Service for the service you want to add

2. Change the “Web reference name” if desired

3. Click Add Reference.

Kommentar hinterlassen

Deine E-Mail-Adresse wird nicht veröffentlicht. Erforderliche Felder sind mit * markiert.

*

code