local variables in WinForms projects are not captured by debugger
See original GitHub issueCreated based on this discussion.
.NET version
net6.0-windows; net7.0-windows; net472
V.S.
Microsoft Visual Studio Community 2022
Version 17.4.2
VisualStudio.17.Release/17.4.2+33122.133
Microsoft .NET Framework
Version 4.8.09032
17.4.1 and 17.5.p1 - same behavior.
Windows.
OS Name Microsoft Windows 11 Home
Version 10.0.22621 Build 22621
Issue description
V.S. Debugger not capturing local variables in any WinForms .Net / .net framework projects. In console projects all are ok: Reset settings and repair installation - nothing helps.
developercommunity issues: https://developercommunity.visualstudio.com/t/Net-local-variables-not-captured-by-deb/10216016 (closed in favor of next one) https://developercommunity.visualstudio.com/t/CS0103-in-the-watch-window-for-local-var/10222843
Steps to reproduce
Any WinForms project.
Issue Analytics
- State:
- Created 9 months ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
variable values not showing during debug vs 2019 16.2.4
As shown in the code below, I have set two break points, one where I add together two local variables, and one when...
Read more >Debugger doesn't recognize local variables.
I'm trying to debug a method and the debugger doesn't recognize almost any variables. Please help me reroduce this error.
Read more >Visual studio debug variable not working
I have some strange issue while debugging. I tried resetting options, changing debug options. Reinstall multiple times following official ...
Read more >7 Ways to Look at the Values of Variables While ...
Hover over a variable to see its value. The most commonly used way to look at variables is the DataTip. When stopped in...
Read more >Debugger, watch: local variable is not captured in Android ...
Debugger, watch: local variable is not captured in Android setOnClickListener lambda · 1.Have some code that you want to debug. · 2. put...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Verified it in different VS versions: cannot repro in 17.3.7 release build and previous versions. Repro in 17.4.2 release build for Winforms .Net Core and .Net framework apps. Doesn’t repro in WPF app.
My VM is Win10 22H2 with different release Visual Studios installed, from 17.4.2, this issue is reproduced.