Upgrade to Visual Studio 2015 and now can't hit break points in debugging

前端 未结 18 1446
北恋
北恋 2020-12-29 21:03

I have a multi-project solution that I was building in Visual Studio 2013 and it was working fine but now that I have upgraded to Visual Studio 2015 I can no longer hit brea

相关标签:
18条回答
  • 2020-12-29 21:35

    I just fixed this issue for one of our front end developers. It may or may not apply to you. We use IIS Express for local debugging, and somehow his had become detached from the correct process when debugging.

    To fix, I checked what process ID it was attached to according to IIS Express (right click IIS icon on taskbar, select Show All Applications, check the PID listed for the application). I then attached it to the proper process (with the solution running in VS, click Debug on the toolbar, select attach to process, find the correct process using the PID gotten above from IIS Express). Hope this helps someone.

    0 讨论(0)
  • 2020-12-29 21:43

    My project was an MVC web app, and when i was running the project with debugger, a new tab was opening in browser which was redirecting me to login page. But in another tab i had logged in user which could do anything, but it wasn't hitting the breakpoints, even though i was hard refreshing the page. And every time i was closing the newly opened tab that was redirecting to login page. Once, i closed old tab with logged in user and actually logged in to app again in the newly opened tab. Then it started to hit the break points.

    0 讨论(0)
  • 2020-12-29 21:44

    I was never able to get it to work with the above methods and finally rolled back to VS 2013 for the solution which worked fine. It is very upsetting that VS2015 feels much like VS2005 when it moved from the stable robust VS2003.

    I hope 2017 resolves these inconsistencies.

    0 讨论(0)
  • 2020-12-29 21:45

    You may leave everything as-is, just take care of the following:

    • Advanced Compiler Settings -> Generate debug info -> has to be either "pdb-only" or "full"
    • Advanced Compiler Settings -> Enable optimizations -> needs to be UNCHECKED
    0 讨论(0)
  • 2020-12-29 21:45

    uninstalling postsharp nuget solved my problem, it is explained in this post https://doc.postsharp.net/uninstalling

    0 讨论(0)
  • 2020-12-29 21:46

    If you only hit breakpoints in the startup project:

    • Tools > Options > Projects and Solutions > Build and Run
    • Uncheck Only build startup projects and dependencies on Run

    And here it is in German:

    0 讨论(0)
提交回复
热议问题