How do I setup a WCF Data Service with an ADO.NET Entity Entity Model in another assembly?

Posted by lsb on Stack Overflow See other posts from Stack Overflow or by lsb
Published on 2010-05-04T03:18:41Z Indexed on 2010/05/04 3:28 UTC
Read the original article Hit count: 162

Hi! I have an ASP.NET 4.0 website that has an Entity Data Model hooked up to WCF Data Service. When the Service and Model are in the same assembly everything works. Unfortunately, when I move the Model to another "shared" assembly (and change the namespace) the service compiles but throws a 500 error when launched in a browser. The reason I want to have the Model in a common assembly (lets call it RiaTest.Shared) is that I want share common validation code between the client and service (by checking "Reuse types in referenced assemblies" in the Advanced tab of the Add Service Reference dialog).

Anyway, I've spent a couple of hours on this to no avail so any help in the regard would be appreciated...

© Stack Overflow or respective owner

Related posts about wcf-data-services

Related posts about ado.net-entity-data-model