Consuming a Web Service

Although Web Services are formally a part of ASP.NET, you can write client applications that take advantage of the Web Services that run either on the client or on a Web server. In this section, you'll create a client-side application, using Windows Forms, to demonstrate the techniques involved in consuming an XML Web Service.

When you decide to consume a Web Service as part of your application, the Web Service might be located on your local intranet, it might be located at a corporate office that's only accessible through the Internet, or it might be a public service. Whatever the scenario, the steps to consume the service are the same. In general, you'll always need to perform these steps:

1.
Add a Web Reference, retrieving ...

Get ASP.NET Developer's JumpStart now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.