Skip to content


Visual Studio VS 2010 not stopping at breakpoints

Ever wondered why suddenly you cannot debug because the compiler isnt breaking on your breakpoints.

There are several reasons for this.

make sure that.
1. Your project is compiling when you begin debugging (check this in build > configuration manager)
2. Ensure your projects are compiling in debug mode not release (check this in build >configuration manager)
3. In the Webconfig ensure you are in debug mode

4. The (project properties > startup options > debuggers has the ASP.NET checkbox checked)
5. Delete all pdb files in your bin folder
6. Ensure every project referenced is set to build under (build > configuration manager)
7. Do a full clean and rebuild. (build > clean solution) (build > rebuild solution)

Finally and this is the one that caught me out
8. Check you are not setting a cookie cache timeout of positive time, I was expiring my page after 1 day. The best way to check this is to load a page in debug, knowing your break point will not be stopped at. Once the page is fully loaded hit ctrl F5 to force full reload of the page. If your breakpoint is stopped at then you know its a cache problem.

Posted in .NET, Annoyances, Configuration, Development.


4 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

  1. Rizvi says

    Tanks this post was useful to me. Saved hours in my work.

  2. Berry says

    OK, this doesn’t seem to address my problem. I’m writing a Windows Forms app, not a Web app, so there is no Web.config. I’ve been debugging a form validation issue, and quite suddenly Visual Studio just stopped hitting all breakpoints. Thinking my system might be overtaxed, I closed down VS and rebooted. After booting back up and launching VS again, I find that the issue remains. I have changed nothing in Visual Studio or project settings. It just stopped hitting breakpoints.

    This is Visual Studio 2010, version 10.0.40219.1 SP1Rel. The application is on .NET version 4.0 Client Profile, and is sitting atop two class library projects, both on .NET 4.0. The application is an MDI app, and I am working in a form that is being raised as a dialog.

    Any ideas? Thanks in advance.

  3. Berry says

    Heh. Found the problem. Evidently VS was overtaxed, and in one of those weird behavioral quirks (I’ve seen all kinds of odd behavior when it’s been running too long), that particular form lost all of its event handlers. I recreated the handlers and got my breakpoints back.

  4. Monir says

    number 8, arghhhhhhhhh it’s been 10 days and all it took ctrl + f5 :S

    thanks a lot. that was more than helpful



Some HTML is OK

or, reply to this post via trackback.