Method 'XYZ' cannot be reflected

后端 未结 9 527
北荒
北荒 2020-12-11 04:26

We have consumed a third party web service and are trying to invoke it from an ASP.NET web application. However when I instantiate the web service the following System.Inval

9条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-11 04:42

    I had the same issue but I found that one of the WebMethod parameters has a member that is of type interface that is why VS could not serialise it. here is the exception when trying to download the disco file

    System.InvalidOperationException: Cannot serialize member 'Leopard.JobDespatchParameters.SendingUser' of type 'Leopard.Interfaces.IUser', see inner exception for more details. ---> System.NotSupportedException: Cannot serialize member Leopard.JobDespatchParameters.SendingUser of type Leopard.Interfaces.IUser because it is an interface.

提交回复
热议问题