Microsoft KB Archive/814717

= BUG: &quot;Unable to start debugging on the Web server&quot; error message when you run an ASP.NET Web application =

Article ID: 814717

Article Last Modified on 12/3/2007

-

APPLIES TO


 * Microsoft .NET Framework 2.0
 * Microsoft .NET Framework 1.1
 * Microsoft .NET Framework 1.0
 * Microsoft Visual Basic .NET 2003 Standard Edition
 * Microsoft Visual Basic .NET 2002 Standard Edition
 * Microsoft Visual C# .NET 2003 Standard Edition
 * Microsoft Visual C# .NET 2002 Standard Edition

-



SYMPTOMS
You create an ASP.NET Web application by using localhost as the Web server, and you change the Web site setting in Microsoft Internet Information Services (IIS) to use the specific IP address for Web Site Identification. Then, when you run the application, you receive the following error message:

Error while trying to run project: Unable to start debugging on the web server. Could not start ASP.NET or ATL Server debugging.

Verify that ASP.NET or ATL Server is correctly installed on the server.



CAUSE
This problem occurs because the debugger does not send the debug action to IIS when you run the application. The debugger identifies your computer as localhost. However, in IIS, the Web Site Identification of the application is the IP address that you specified.



RESOLUTION
 In a text editor such as Notepad, open the .vbproj.webinfo file.

Note In a Visual C# .NET project, this is the .csproj.webinfo file.

This file is located in the application folder for the application project.  Locate the following line.

Visual Basic .NET /.vbproj&quot; /> Visual C# .NET /.csproj&quot; />   Replace &quot;localhost&quot; with the IP Address of your computer as follows.

Visual Basic .NET /.vbproj&quot; /> Visual C# .NET /<WebApplicationName>.csproj&quot; /> </li> Start Microsoft Internet Explorer. On the Tools menu, click Internet Options.</li> In the Internet Options dialog box, click the Security tab. Under Select a Web content zone to specify its security settings, click Local Intranet, and then click Sites.</li> In the Local Intranet dialog box, click Advanced.</li> In the Add this Web Site to the zone box, type the URL of your project, and then click Add.</li> Close the application, and then open the application again.</li> On the Debug menu, click Start.</li></ol>

<div class="status_section">

STATUS
Microsoft has confirmed that this is a bug in the Microsoft products that are listed in the &quot;Applies to&quot; section.

<div class="moreinformation_section">

Steps to reproduce the problem

 * 1) In Microsoft Visual Studio .NET, create a new Web Application project or a new Web site project by using Visual Basic .NET or Visual C# .NET. In the New Project dialog box, type http://localhost/testapp in the location box.
 * 2) Click Start, click Run, type inetmgr, and then click OK.
 * 3) In Internet Information Services (IIS) Manager, expand (local computer), and then locate Default Web Site.
 * 4) Right-click Default Web Site, and then click Properties.
 * 5) In the Default Web Site Properties dialog box, click the Web Site tab. In the IP address list, click the IP address of your computer. Click OK, and then close IIS Manager.
 * 6) On the Debug menu, click Start.

<div class="references_section">