AJAX启用WCF服务以实现级联下拉方法404错误

时间:2021-07-17 20:28:57

I am new to WCF issues and I'm trying to populate an control by using a wcf service . I have used 'Ajax-Enabled WCF' template ( VS 2010) for creating my service. there is no error while on Asp.net development server but when put on IIS [Method 404 Error] appears in dropdown . I tried to access the WCF services directly like (https://sitename/webservice/test.svc) it shows the documentation page.

我是WCF问题的新手,我正在尝试使用wcf服务填充控件。我使用'Ajax-Enabled WCF'模板(VS 2010)来创建我的服务。在Asp.net开发服务器上没有错误,但是当放在IIS上时[方法404错误]出现在下拉列表中。我尝试直接访问WCF服务,如(https://sitename/webservice/test.svc),它显示了文档页面。

I have searched for hours to find a solution but no use. I will be thankful if anyone can help me out

我已经搜索了几个小时才找到解决方案,但没有用。如果有人能帮助我,我将感激不尽

Thanks

谢谢

2 个解决方案

#1


0  

Can you connect to your IIS hosted service via WcfTestClient (see under Tools)? Also check the endpoint address in App.config on your client...If that does not work, could you post client's App.config and Web.config from Service's IIS?

您可以通过WcfTestClient连接到您的IIS托管服务(请参阅工具)?还要检查客户端上App.config中的端点地址...如果这不起作用,您可以从Service的IIS发布客户端的App.config和Web.config吗?

#2


0  

I had similar issue, where it worked on dev server, but not Integration (got 404, service is not defined error). The issue was the .svc file type was not mapped in IIS, which fixed the issue.

我有类似的问题,它在dev服务器上工作,但不是Integration(得到404,服务没有定义错误)。问题是.svc文件类型未在IIS中映射,这解决了问题。

#1


0  

Can you connect to your IIS hosted service via WcfTestClient (see under Tools)? Also check the endpoint address in App.config on your client...If that does not work, could you post client's App.config and Web.config from Service's IIS?

您可以通过WcfTestClient连接到您的IIS托管服务(请参阅工具)?还要检查客户端上App.config中的端点地址...如果这不起作用,您可以从Service的IIS发布客户端的App.config和Web.config吗?

#2


0  

I had similar issue, where it worked on dev server, but not Integration (got 404, service is not defined error). The issue was the .svc file type was not mapped in IIS, which fixed the issue.

我有类似的问题,它在dev服务器上工作,但不是Integration(得到404,服务没有定义错误)。问题是.svc文件类型未在IIS中映射,这解决了问题。