VS. NET Common Errors in debugging. NET

Source: Internet
Author: User

1. When debugging ASP. NET applications, an error message "the project is not configured for debugging" is displayed.

Symptom

When you debug an ASP. NET application in Visual Studio. NET, the following error message may appear:

Error while trying to run project: Unable to start debugging on the web server. The project is not configured to be debugged

For ASP. NET projects, verify that you have a valid project file called 'web. config' for the URL specified and 'debug' is set to 'true' in that file.
For ATL Server projects, verify that the 'debug' verb is associated with your ISAPI extension.
Wocould you like to disable future attempts to debug ASP. NET pages for this project?

Cause

This error is mainly caused by the following reasons:

The ASP. NET application does not have the Web. Config file.
The execution permission attribute of the current project folder in "Internet Service Manager" is set to none.

Solution

To solve this problem, use one of the following methods based on your environment:

If your project does not have a Web. config file, add a Web. config file to the directory containing the ASP. NET application. If you are working in Visual Studio. NET, right-click the project in "Project Resource Manager", click Add new project, and then click Web configuration file.

If your project already has Web. config file, and the Web. in the "Compilation" section of the config file, set the debug attribute to true. Follow these steps to set the execution permission attribute of the project folder:

1. Start "Internet Service Manager" and click the project you want to debug.
2. Right-click the project and click Properties.
3. Click the Directory tab.
4. If you select none in the execution permission list, Click Show script only and then click application.

2. An error message "cannot start debugging" appears when sending an HTTP request for debugging.

Symptom

When you debug an ASP. NET application in Visual Studio. NET, the following error message may appear:

Error while trying to run project: Unable to start debugging on the web server. Server-side error occurred on sending debug HTTP request.

Make sure the server is operating correctly. make sure the server is operating correctly. you may also want to refer to the ASP. NET and ATL Server debugging topic in the online documentation. wocould you like to disable future attempts to debug ASP. NET pages for this project?

Cause

This problem occurs if a syntax error occurs in the Web. config file of an ASP. NET application.

Solution
To solve this problem, make sure that the Extensible Markup Language (XML) in the Web. config file is in a valid and correct format. In addition, remember that all characters in Web. config are case sensitive.

3. Access denied when debugging ASP. NET applications. Check the DCOM configuration settings of the Computer debugging manager. "Error message


Symptom

When you remotely debug an ASP. NET application in Visual Studio. NET, the following error message may appear:

Error while trying to run project: Unable to start debugging on the web server. access is denied. check the DCOM configuration settings for the machine debug manager. wocould you like to disable future attempts to debug ASP. NET pages for this project?

Cause

This error occurs because the user attempting to perform remote debugging is not a member of the "Debugger user" group on the Microsoft Internet Information Server (IIS) Server.
Solution
To add an appropriate user to the debugger user group, perform the following steps on the Web server:
1. From the Windows Start Menu, point to program, point to management tools, and then click computer management.
2. In the left pane, click to expand computer management, system tools, and local users and group nodes.
3. Click the group and double-click the debugger user.
4. In the debugger User Properties dialog box, click Add.
5. In the select user or group dialog box, select the appropriate user and click OK.
6. Click OK to exit the debugger user Attributes dialog box.
7. Disable "Computer Management" Resource Manager.

4. error message "cannot start debugging on Web server" appears during ASP. NET application debugging

Symptom

When you debug an ASP. NET application in Visual Studio. NET, the following error message may appear:

Error while trying to run project: Unable to start debugging on the web server. wocould you like to disable future attempts to debug ASP. NET pages for this project?

Cause

This error occurs because Microsoft Internet Information Server (IIS) is not running or is not running properly.

Solution

To solve this problem, you must restart IIS. To do this, type iisreset at the command prompt.

5. When debugging ASP. NET pages, the Visual Studio. NET debugger does not stop at the breakpoint.

Symptom

When debugging ASP. NET Applications in Visual Studio. NET, the debugger may not stop at the breakpoint.

Cause

This problem occurs because ASP. NET debugging is not enabled in the application.

Solution

To solve this problem, follow these steps in Visual Studio. NET:
1. In Solution Explorer, select a project name.
2. Click properties in the project menu.
3. Click to expand the configuration attribute node.
4. In the Enable ASP. NET debugging list under debugging, click True.

6. Unable to debug ASP. NET Web applications

Symptom

When you debug an ASP. NET application in Microsoft Visual Studio. NET, the following Microsoft Development Environment error message may be displayed:

Error while trying to run project: Unable to start debugging on the web server. the server does not support debugging of ASP. NET or ATL Server applications. run setup to install the Visual Studio. NET server components. if setup has been run, verify that a valid URL has been specified.

You may also want to refer to the ASP. NET and ATL Server debugging topic in the online documentation. wocould you like to disable future attempts to debug ASP. NET pages for this project?

Cause

This error may occur if Microsoft. NET Framework settings or installation is not completed correctly. When this error occurs, the application ing of the ASP. NET file extension (such as. aspx) is not correctly configured in Microsoft Internet Information Service (IIS.

To check whether the application ing is correct, follow these steps:
1. Click Start, point to program, point to administrative tools, and then click Internet Service Manager.
2. Expand the node corresponding to the local host (computer name), and then expand the default Web site node.
3. Right-click the Web application directory and click Properties.
4. Under application settings on the Directory tab, click Configure.
5. Click the application ing tab.
6. Under application ing on the application ing tab, check whether the. aspx extension is mapped to the following dynamic link library (DLL ):
C: \ Windows Directory \ Microsoft. Net \ Framework \ v1.0.3705 \ aspnet_isapi.dll

Note: you must replace Windows Directory in this path with the correct Directory of your system.

7. If no application ing entry is found, follow the steps in solution.

Solution

To solve this problem, use the Aspnet_regiis.exe management utility, which manages the installation and uninstallation of multiple versions of ASP. NET on a single computer.

To use the Aspnet_regiis.exe utility, follow these steps:
1. Click start, and then click Run.
2. Type cmd in the open box, and click OK to open the command prompt.
3. In the command prompt, type the cd command to change to the following directory:
C: \ Windows Directory \ Microsoft. Net \ Framework \ v1.0.3705

4. Type aspnet_regiis-I to correctly configure the application ing.

Error while trying to run project: Unable to start debugging on the web server. Access is denied. wocould you like to disable future attempts to debug ASP. NET pages for this project?

Verify that you are a member of the "Administrator" group and "Debugger user" group on your computer. The non-Administrator does not have the correct permission to debug the ASP. NET auxiliary process (Aspnet_wp.exe.

Date: 2004-6-20 15:54:37 Source: weste
 

Supplement:

Introduction

During the last several months, I have dealt with your users from both inside and outside of Microsoft who have debugging issues. I noticed that there are missing common mistakes and problems that can be solved, if users are provided with proper diagnosis. hence, I 've written this document to provide you with this information which will help you if you run into any issues while using the debugger.

This document contains:

  • Error message dialog or description of error situation
  • The causes for error
  • How to fix the problem.

And I especially thanks to VCS debugger team and other people who helped me to complete this document with various feed back.

Debugging issues

ASP. NET Debugging

* If you can't find the error message that you're looking for in this section, please check the section which deals with general debugging issues or remote debugging issues.

 

Message: Unable to start debugging on the web server

Your IIS application of IIS is not configured to use "integrated Windows authentication". Please make sure that the "integrated windows authentication" checkbox on the "authentication method" dialog box is checked.

Message: You do not have permission to debug the server

 

  • Cause 1: Make sure that "Integrated Windows Authentication" is enabled. Probably, you enabled only "Basic authentication" for Directory security of IIS.

  • Cause 2: If you are using "Integrated Windows authentication", you need to make sure that your user account has full control on the directory of the IIS.
  • Cause 3: If you created the web project with a full machine name (like "machinename. domainname. the web site is recognized as "Internet" site. so the default setting of IE will impact on the behavior of log on. in this case, you need to enable logging on with your current user account in "Internet" area with IE setting.

    But it is not the default setting of IE, so you 'd be better off if you create project with only the machine name.

Message: Server side-error occurred on sending debug HTTP request.

 

Cause 1: Your web application doesn't have an Application name. Please check the properties of the web project using the iis mmc to ensure that your web project has an application name

You need to create an application name for debugging.

Cause 2: If you are using the NTFS file format, please make sure that "aspnet" has proper privilege on "wwwroot" or your folder for virtual directory to access and write on the folders.

Message: The project is not configured to be debugged.

 

You need to make sure that your web is configured for debugging. to do this, you need set "debug = true" in the "web. config "file. you may find this file in your web project folder.

Can start debugging without error message, but breakpoints are not hit.

You started debugging with "F5" and it looks like debugging is started properly, and IE is launched properly. But you can't hit a breakpoint on my code behind code.

 

Cause 1: Please make sure that "asp.net debugging" is enabled in the properties of project.

In the case of VB project, the UI is different. But you can recognize the equivalent one easily.

Cause 2: Please make sure that the expected DLL is loaded with matched debug symbol file. You can check it with "Modules" window.

Message: The debugger is not properly installed.

 

If you see this problem, please check debugging with console application project. And if the console application project shows the error message like

It means that your. Net framework is not installed properly. So you need to register "mscordbi. dll" manually by executing "regsvr32 mscordbi. dll ".

Message: The server does not support debugging of ASP. NET or ATL server applications.

 

If you have an XP Pro or W2K Pro machine, you may need to think about the order of installation between VS7 and IIS. if you install IIS after VS7, you will get this error. in this case, please register "aspnet_isapi.dll" with your aspnet_regiis.exe-I ".

Message: Access is denied. Verify that you are an administrator or a member...

 

You may not be the member of "Debugger users" group on the machine. Please add your user account into "Debugger users" group on the machine.

To add your user account into "Debugger users" group, you need to do the following:

1. Log in as "Administrator"

2. Run "Computer management" in "Administrator tools"

3. Choose "Local users and groups" node

4. Double-click "Debugger users" group on right pane.

Error while trying to run project: Unable to start debugging on the web
Server. The project is not configured to be debugged.

IIRC this is due the folder in the IIS webserver is not configured as
APP

Go to IIS, right click the dir and select create app

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.