Reputation: 519
I am working on Dotnet Core + Angular application with Visual Studio 2019. After publishing code in release mode and deployed on IIS. When I changed the code to debug and tried to debug something the breakpoints are not getting hit on any controller. Does anybody ever faced this problem, it would be helpful to have any solution on this. Here is my project properties
Upvotes: 0
Views: 1434
Reputation: 23868
Visual Studio 2019 break point is getting hit
This is indeed a very strange behavior and I suggest you could try these suggestions to troubleshoot your issue:
Suggestion
1) Right-click on your project-->Properties-->Build-->Advanced-->change Debugging Information
to Full
.
2) make sure that you use IIS Express with Google Chrome or change to use IE to debug your project
3) Tools
--> Options
-->Debugging
-->Symbols
--> select Microsoft Symbol Servers
-->Click Load All Symbols
4) close VS Instance, delete .vs
hidden folder under solution folder, bin
, obj
folder and then restart your project to test again.
Update 1
Based on your issue, JS sent request to Core and could not enter the breakpoint, you can try these steps:
1) enable option Javascript Debugging for Asp.Net(Chrome,Edge and IE)
under Tools
-->Options
-->Debugging
-->General
2) If you try to debug js on cshtml, you should move these js into a single javascript file and then reference such js file in cshtml. You can refer to this link.
Hope it could help you.
Upvotes: 1