VS2012 Breakpoints are not getting hit

后端 未结 24 1647
小鲜肉
小鲜肉 2020-12-13 12:44

I have a class that looks like this:

public class MyService
{
    private MyService(){}
    public static string GetStuff()
    {
        var stuffDid = new          


        
24条回答
  •  北海茫月
    2020-12-13 13:12

    I had this happen in a 1 project out of 25 which were all in the same solution. The other projects honored breakpoints but this 1 didn't. I removed the project from the solution (delete, not unload) which broke all references to it and then added it back to the solution and that worked!

    If that doesn't work you may want to recreate the problem project from scratch and add that new project to the solution.

    The best explanation I have for why this worked apart from pure luck is that we migrated projects from one version of VS to another many, many times over the years and maybe one of those migrations caused this problem.

提交回复
热议问题