user7496931
user7496931

Reputation: 1519

Unbound Breakpoints?

enter image description here

I've been having trouble running some breakpoints after my code is built and ran. My project is on ASP.NET. I'm using VS 2022 and so far I have tried the following things:

To be specific, the breakpoint is solid when set, but becomes hollow and unbound when my code is ran. Any suggestions? How can I fix this?

Upvotes: 10

Views: 10965

Answers (2)

Kiran Gaikwad
Kiran Gaikwad

Reputation: 1

I have the same problem i did everything what mentioned in the above comment but it is unresolved then when i check startup project i found i have added additional things to it, when i undo this project file changes like below changes then i solved my issue.

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
   <Optimize>True</Optimize>
 </PropertyGroup>

If debugger is not working in your project then try to run it on another project which you have created newly then you guaranteed that it is not related to your project specific.

Upvotes: 0

Andrew
Andrew

Reputation: 20061

I had this same problem recently on Microsoft Visual Studio Enterprise 2022 (64-bit) - Preview Version 17.4.0 Preview 6.0.

This fixed it for me:

  1. Right click solution > Set Startup Projects
  2. (Make sure they are set to "Start" and not "start without debugging" while you are here)
  3. Click Configuration Properties
  4. Change Configuration for your projects from Release to Debug.

Might need to change these back to Release before deploying...

Upvotes: 6

Related Questions