Creating a Web Service Client Proxy

Visual Studio .NET has a wizard that generates a Web-service-client proxy that allows you to call Web-service methods.

You can start the wizard in Project > Add Web Reference.

  1. To start the wizard, click Project > Add Web Reference.
  2. In the corresponding text box, type the URL of your Web service and press Enter. For example,
  3. If the wizard can load the WSDL document from the URL, click Add Reference. The wizard generates a proxy class in a namespace, which is the reverse of the name of the Web server that hosts the service.
Explore projects to see which classes are generated. Each web service, and all complex data types used by the Web-service methods, are represented as classes. So in the example URL above, there is Service1, which is a Web service, and User, which is a complex parameter.