I have a huge problem getting service references in VS2010 RC to use existing assemblies.
Despite the fact that I have a class library with all data contracts (classes labeled DataContract and properties with DataMember) that are shared between the service project and the consumption project (which is the class library), when I add a reference to the service, the data contracts are restored using a service reference instead of using existing types.
When I used VS2010 beta 2, it worked fine, and I have existing links to services using the same data contracts. But if I add a new service link or even update an old one, it will no longer use existing types.
I made a mini-test solution with one service, one type of contract with data and one console application as a consumer (all in the same solution), and it works there, but there wasn’t much comfort for me, Is there any way to understand why it can't use existing types?
Change to clean. It works to create proxy classes using svcutil.exe and points to the dll of the dll data, for example:
svcutil.exe http:
The question is, what is the possible reason for Visual Studio to generate its own datacontracts instead of using existing ones, even if the "reuse" checkbox is checked and the link to datacontracts is referenced.
source share