且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

发布WCFService不起作用;调试模式

更新时间:2023-01-02 21:33:47

首先,请使用WCF服务应用程序项目模板,

否则,将不会启动Appconfig文件.库项目需要在托管环境中进行其他配置,并且无法识别Appconfig文件.我们必须将配置代码移到您的托管环境可以识别的配置文件中.

随时让我知道问题是否仍然存在.

At first, please use the WCF service application project template,

or the Appconfig file would not be kicked in. library project needs the additional configuration in the hosting environment, and the Appconfig file could not recognized. We have to move the configuration code into the configuration file recognized by your hosting environment.
https://docs.microsoft.com/en-us/dotnet/framework/wcf/deploying-a-wcf-library-project
Secondly, for hosting the WCF service in IIS, we should enable the below windows feature.
Feel free to let me know if the problem still exists.