tags:

views:

276

answers:

1

Hi All,

I have a WCF service library containing two services. These two services share a common set of classes in their operations.

When I generate the WCF proxies with svcutil.exe, I get two sets of proxy classes (one for each service). Is there any way to have it only generate one set of these shared classes? Or will I have to partition these classes into separate namespaces?

A: 

You can supply multiple service endpoint URI's to the svcutil.exe command line. When you specify more than one endpoint URI, any types that share a common schema will be generated once and reused amongst all service contracts.

http://msdn.microsoft.com/en-us/library/aa347733.aspx

jrista