Reputation: 4826
Running a particular project in Debug, Visual Studio is always stopping at the Public Sub New()
line in my main form (it's an older project, so the code is within a autogenerated region in the .vb file rather than a .designer.vb file). No idea why this is happening and it's becoming a headache. It doesn't happen in any of my other VB projects (or running under Release). I can just hit F5 and it continues as normal.
Things I have tried:
I should note that both before and after doing the above, there is no breakpoint symbol next to the line. The execution just pauses and the line gets highlighted with a yellow arrow, as with a normal breakpoint line.
Why would VS be breaking at this opening line even without any breakpoints? I'm pretty sure I deleted the relevant files, so I would guess there's a VS setting I can't seem to find (but if it's a setting, wouldn't it affect other projects as well?).
Also, there are multiple developers working on this project. I am the only one this happens to.
Upvotes: 0
Views: 749
Reputation: 4826
The issue was that "Enable Just My Code" was turned off in my debug settings.
I'm still not entirely sure why that caused it to break at this particular line without a breakpoint attached (other projects don't break here, even my fellow developer didn't have this issue after matching his settings with mine and debugging the same project...), but after checking this option, it no longer breaks at that first line.
Upvotes: 1