WCF common types not reused

前端 未结 7 1390
梦如初夏
梦如初夏 2020-12-09 04:53

Hint: This questions has many duplicates, but none of the solutions works for me.

What I have is a web service and a client, both having references to a shared assem

7条回答
  •  心在旅途
    2020-12-09 05:05

    After checking all the answers here, nothing worked. Then I realized that my service had an error when viewing the wsdl in the browser. This should be obvious right? Well, see what happened is I opened the service's solution file as a different(none admin) user and updated the name of one of the reusable types. Built my solution and everything built successfully. Which is when I ran into the issue described by the OP.

    What happened was, because I logged in with a non-admin account and I wasn't using IIS express. My WCF project did not load. Meaning that the rename of the type did not take effect in the WCF project. Thus causing the issue.

    TLDR; make sure your service actually starts and works correctly, before looking for issue in the consuming application.

提交回复
热议问题