0
我最近將一個ASP.Net應用程序從.Net framework 3.5升級到4.0。該應用程序包含一個WCF服務,升級後它返回一個404錯誤。疑難解答404 WCF服務錯誤
的錯誤信息是如下:
Server Error in '/' Application.
--------------------------------------------------------------------------------
The resource cannot be found.
Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly.
Requested URL: /ws/ProviderService.svc
--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET Version:2.0.50727.42
web.config中有
<error statusCode="404" redirect="Common/Pages/404b.htm"/>
,它應該重定向404對自定義頁面。如果我嘗試訪問不存在的.asmx服務,則它會正確重定向到404b.htm頁面。
它看起來像.NET框架4.0不處理,但不知何故被.Net框架2.0拾起。
該網站是IIS7和Windows Server 2008
任何想法呢?