ASP.NET开发Web服务器坏了

时间:2022-12-30 02:01:46

I had VS 2005 with v2.0 of the framework. Then I installed NDoc recently and that supports only v1.1, so it installed v1.1 on top of v2.0. That is fine because both versions can co-exist but what it did was screw up some settings with:

我有VS 2005与框架的v2.0。然后我最近安装了NDoc并且仅支持v1.1,因此它在v2.0之上安装了v1.1。这很好,因为两个版本可以共存,但它做的是搞砸了一些设置:

a) The web server that comes with ASP.NET, the one you run your web services on in debug mode.

a)ASP.NET附带的Web服务器,即在调试模式下运行Web服务的Web服务器。

b) SQL Server's active CLR settings (but this isn't bothering me as much)

b)SQL Server的活动CLR设置(但这并不困扰我)

c) IIS settings (but I fixed this by re-registering IIS with 2.0)

c)IIS设置(但我通过使用2.0重新注册IIS来修复此问题)

What's bothering me to the hilt now is the broken ASP.NET web server won't allow me to debug my Web services or even have another project in the same solution create a web reference to it.

现在困扰我的是那个破碎的ASP.NET Web服务器不允许我调试我的Web服务,甚至在同一个解决方案中有另一个项目创建一个Web引用。

I can't generate proxies in Visual Studio because of this, nor can I set a web reference to a web service in the same solution (as it involves generating a proxy).

因此,我无法在Visual Studio中生成代理,也无法在同一解决方案中设置Web服务的Web引用(因为它涉及生成代理)。

Note that I can call wsdl.exe though. But I don't want to deploy my service yet. I just want all projects in the same solution referencing the ws like well-behaved little kids.

请注意,我可以调用wsdl.exe。但我还不想部署我的服务。我只是希望同一解决方案中的所有项目都能像乖巧的小孩一样引用ws。

When I do try to create a web reference to the WS project in my solution, I keep getting this error:

当我尝试在我的解决方案中创建对WS项目的Web引用时,我不断收到此错误:

Server Error in '/' Application.

Parser Error Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

分析程序错误说明:解析为此请求提供服务所需的资源时发生错误。请查看以下特定的解析错误详细信息并相应地修改源文件。

Parser Error Message: Could not create type 'DaWS.PhoneDirectory'.

分析器错误消息:无法创建类型“DaWS.PhoneDirectory”。

Source Error:

Line 1: <%@ WebService Language="C#" CodeBehind="PhoneDirectory.asmx.cs" Line 2: Class="DaWS.PhoneDirectory" %>

第1行:<%@ WebService语言=“C#”CodeBehind =“PhoneDirectory.asmx.cs”第2行:Class =“DaWS.PhoneDirectory”%>

Source File: /PhoneDirectory.asmx Line: 2

源文件:/PhoneDirectory.asmx行:2


Version Information: Microsoft .NET Framework Version:2.0.50727.3082; ASP.NET Version:2.0.50727.3082

版本信息:Microsoft .NET Framework版本:2.0.50727.3082; ASP.NET版本:2.0.50727.3082

It's been nagging me for days now and I've been managing with deploying in IIS.

它已经唠叨了我好几天了,我一直在管理IIS中的部署。

Other than re-install Visual Studio, does anyone have a better solution?

除了重新安装Visual Studio,有没有人有更好的解决方案?

1 个解决方案

#1


Create a new web service, and do not change it at all. See if it works.

创建一个新的Web服务,根本不要更改它。看看它是否有效。

BTW, the fact that this page displays .NET 2.0 and not 1.1 suggests version is not the problem.

顺便说一句,这个页面显示.NET 2.0而不是1.1建议版本的事实不是问题。

#1


Create a new web service, and do not change it at all. See if it works.

创建一个新的Web服务,根本不要更改它。看看它是否有效。

BTW, the fact that this page displays .NET 2.0 and not 1.1 suggests version is not the problem.

顺便说一句,这个页面显示.NET 2.0而不是1.1建议版本的事实不是问题。