Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio 2015 RTM - Debugging not working

I have installed VS 2015 RTM (nothing else) and I'm unable to debug any solution, not matter if it's an existing one or a brand new one (created with VS 2015 and compiled against .Net Framework 4.6), it only opens a new tab in VS which is called Break Mode with the following text: The application is in break mode Your app has entered a break state, but no code is executing that is supported by the selected debug engine (for e.g. only native runtime code is executing). And if I check the Debug --> Module Window: VS2015Test.vshost.exe no symbols loaded (even if I click load symbol it does not work) VS2015Test.exe symbols loaded

And it also doesn't show the output on the console(it's a console application that just has the following lines of code:

class Program
{
        static void Main(string[] args)
        {
            Console.WriteLine("TEST");
            Console.ReadKey();
        }
    }

I tried to reinstall VS 2015, restarted the computer, deleted all files in %temp%/AppData/Microsoft/Visual Studio/14, started VS in Admin Mode but nothing seems to work.

One thing which makes debugging working is this option: Tools --> Options --> Debugging --> Use Managed Compability Mode

^^But that can't be the solution to use an old/legacy mode.

BTW: Debugging in VS 2013 is working fine.

Any help would be appreciated.

like image 530
rene_r Avatar asked Jul 23 '15 06:07

rene_r


4 Answers

In my case this solution is useful:

Solution: Disable the "Just My Code" option in the Debugging/General settings.

enter image description here

Reference: c-sharpcorner

like image 137
mayank Avatar answered Nov 09 '22 16:11

mayank


I was having this same problem with VS2015. I reset the settings, as suggested but still had trouble.

What I had to do to fix it was check "Use Managed Compatibility Mode" and "Use Native Compatibility Mode". Not sure which of those 2 is necessary but checking both and I no longer get the Break Mode issue.

Break Mode Fix - Debug Settings

like image 43
Andy Avatar answered Nov 09 '22 17:11

Andy


I had a very similar issue recently, related to debugging settings.

Firstly have you tried resetting all your settings? I think it may be related to that as you say it is project independent and you've deleted all application data.

Tools-> Import and Export Settings Wizard -> Reset all settings

Don't worry, it gives you the option to save current settings.

Secondly if this fails, I would suggest looking at the event log.

Entering break mode would suggest that the DE (debug engine) is sending a synchronised stop event to visual studio like IDebugExceptionEvent2. I would take a look at the event log for exceptions like failures in loading referenced assemblies (like .NET runtimes, etc) or environment access restrictions.

Something is telling the debugger to stop your running application, its just a case of finding it.

like image 15
garyamorris Avatar answered Nov 09 '22 18:11

garyamorris


Thought I would post this in case it helps anyone. I installed a clean Win 10 and Visual Studio 2015, tried to debug an existing solution and had problems. Followed some advice listed here and other places but none worked.

How I got the debugging to work as normal was to change the Solution Configuration just below the menus. I had it set previously to Release mode, changed this to Debug and then cleaned/recompiled and hey presto, debugging started working as normal. See the image for info:

enter image description here

like image 15
KDee Avatar answered Nov 09 '22 17:11

KDee