WCF service: Returning custom objects

后端 未结 3 1424
小鲜肉
小鲜肉 2020-12-06 17:51

I\'m using WCF service in my application. I need to return a custom object in the service class. The method is as follows:

IService.cs:
[OperationContract]
         


        
3条回答
  •  有刺的猬
    2020-12-06 18:36

    You should return a specific type, not "object". An "object" could be of any type.

提交回复
热议问题