Microsoft KB Archive/303067

= You cannot debug a managed application in Visual Studio .NET if Windows was started in debug mode =

Article ID: 303067

Article Last Modified on 3/10/2006

-

APPLIES TO

 Microsoft Visual Studio .NET 2002 Professional Edition, when used with:  Microsoft Windows 2000 Standard Edition

 Microsoft Windows XP Professional

 Microsoft Windows NT 4.0  Microsoft .NET Framework Software Development Kit 1.0 Service Pack 2</li></ul>

-

<div class="notice_section">

This article was previously published under Q303067

<div class="symptoms_section">

SYMPTOMS
When you try to debug a managed application (one that makes use of the .NET Framework) with Visual Studio .NET software, you may receive the following error message:

Error while trying to run project: Unable to start debugging.

Unable to start program

Debugging isn't possible because a kernel debugger is enabled on the system.

-or-

The debugger is not properly installed. Run setup to install or repair the debugger.

NOTE: The second error message may have other causes and resolutions.

<div class="cause_section">

CAUSE
This problem happens if Windows was started in debug mode on the system. This stops the Visual Studio .NET debugger from debugging managed applications.

To determine whether your system was started in debug mode, see the following Microsoft Knowledge Base article:

244876 How to determine if Windows is started in Debug mode

<div class="resolution_section">

RESOLUTION
There are two ways that you can resolve this problem. Do either of the following:  Resolution 1 <ol> Right-click the   in Solution Explorer, and then click Properties.</li> In the left pane of Properties, click to select Configuration Properties.</li> Click to select Debugging.</li> In the right pane, click to select the Unmanaged code debugging check box.</li></ol> </li> Resolution 2 <ol> In Microsoft Notepad, open Boot.ini, which is located in the  folder (usually C:\). This file may be hidden and read-only, so you may have to use dir /ASH to find it.</li> Remove all of the following switches, if found in the file:  /debug</li> /debugport</li> /baudrate</li></ul>

</li> Restart the computer, start Visual Studio .NET, and then debug.</li></ol> </li></ul>

<div class="references_section">