WCF: how to generate a single WSDL document, without WSDL:import?

前端 未结 6 1263
既然无缘
既然无缘 2020-12-08 05:25

I\'m troubling into an issue... I\'m trying to find a way to generate a single wsdl document from my WCF service, i.e. without any link to external documents. I\'ve used Fla

6条回答
  •  抹茶落季
    2020-12-08 06:03

    This is a late answer, but I had the same problem with a few of our WCF services. If you're on .NET 4.5, like the earlier answer, use ?singleWSDL, but if you're not targeting .NET 4.5 then I added the following to my web.config to fix the issue...

    
      
        
        
      
    
    

    This goes in your behavior. That way I didn't have to flatten the WSDL because all references were to MyURL instead of MyServer.

    Hope this helps others with a similar issue.

提交回复
热议问题