Is there a way to use SPMetal generated classes together with a WCF service application?
I generated entity classes with spmetal using the serialization parameter (set to "unidirectional"). However, when I use those classes as return value for a WCF method, I get the following error:
System.ServiceModel.CommunicationException was unhandled by user cod开发者_高级运维e
Message=The server did not provide a meaningful reply;
this might be caused by a contract mismatch,
a premature session shutdown or an internal server error.
Using my own classes works flawless. The code that SPMetal created can be viewed here: http://pastebin.com/kjEvUAgS
Does anybody know if SPMetal and WCF play together nicely?
精彩评论