Customizing an auto-generated service proxy class in Visual Studio

The Visual Studio Add Service Reference dialog can help in generating a WCF client proxy component through service metadata. However, sometimes we will need to do some customization or adjustment on the generated proxy classes, such as add some custom methods, manipulate some of the method signature, or add additional member properties in the proxy class. In this recipe, we will cover the way to manually modify the auto-generated WCF service proxy class in a Visual Studio project.

How to do it...

In this recipe, we will look at the steps to customize an auto-generated WCF service proxy in Visual Studio by adding custom code.

  1. Generate the WCF service proxy class through the Add Service ...

Get Microsoft Windows Communication Foundation 4.0 Cookbook for Developing SOA Applications 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.