simonk83
simonk83

Reputation: 89

I just can't get the Visual Studio for Mac debugging to work (the option is greyed out)

no idea what I'm doing wrong here. I have two macs at home, one is mine, one is a work laptop. I have VS 2022 Preview installed on both, and .net 6 on both. On my home mac, if I start a new c# Console app I'm able to just stick a break point on the (single) Console.Writeline line, hit debug, and it stops on that line as you'd expect. On my work mac, breakpoints just turn hollow immediately, and debugging the code just runs the code instead. The "Start Debugging" option is just greyed out in the menu bar. I've tried a bunch of things but I just can't work out why this isn't working!

Upvotes: 0

Views: 4288

Answers (2)

havrosh
havrosh

Reputation: 1

I have had the same problem. The extension ".Net Core Debugger" was disabled and therefore I was not able to debug projects.

Go to Visual Studio -> Extensions -> Installed and check the state

Upvotes: 0

Jacques Olivier
Jacques Olivier

Reputation: 26

I had the same issue and all the other solutions I found did not work for me with VS 2022 (v17.0.6), dotnet6.

It appears it is an IDE Issue and hopefully gets fixed soon. Installing Visual Studio 2019 seems to solve it. Credit here: Visual Studio For Mac 2022 - Cannot execute "{...}.exe".

Out of curiosity, the following appears too 'reset' it back to normal.

  1. Set a breakpoint in your code (mine was hollow when doing so)
  2. Select 'Visual Studio' -> 'Quit'
  3. Re-open your solution and navigate back to your breakpoint

But after selecting "Start Debugging" option, it returns back to its previous state of no debugging.

Upvotes: 1

Related Questions