Winforms debug is not working inside form event functions

Where does the bug appear (feature/product)?

C# extension - Base language support for C# (Anysphere) in Cursor IDE

Describe the Bug

Breakpoints inside form event functions do break, but do not really work.
Breakpoints in Main or elsewhere outside UI thread do work normally.
Same project will work just fine in VS Pro.

Steps to Reproduce

Create new winforms project in VS Pro. Add event to Form_Load. Maybe add some variable to the function for testing purposes, but not needed for bug to appear.

Add project in Cursor to workspace.

Open the form and add breakpoint to the added event.

Run the project.

Expected Behavior

Stack shows error "Failed command ‘stackTrace’: 0x800004002.
Variables screen is empty. No highlight for the line where breakpoint is.

In some projects trying to Continue will do nothing, but in blank project it works. Trying Step over/into sometimes show error “Failed command ‘next’ : 0x80131309”, but in blank project just doesn’t work.

I will attach image to show the situation.

Screenshots / Screen Recordings

Operating System

Windows 10/11

Current Cursor Version (Menu → About Cursor → Copy)

Version: 1.5.9 (user setup)
VSCode Version: 1.99.3
Commit: de327274300c6f38ec9f4240d11e82c3b0660b20
Date: 2025-08-30T21:02:27.236Z
Electron: 34.5.8
Chromium: 132.0.6834.210
Node.js: 20.19.1
V8: 13.2.152.41-electron.0
OS: Windows_NT x64 10.0.26100

Additional Information

.NET 9 in use. I have not noticed same behavior with Blazor projects. WFP projects are also working. MAUI is difficult to get working at all in Cursor, so I’m not testing that for this right now.

It was Claude Sonnet 4 who suggested problem might be in the C# Extension because it is not official Microsoft with OmniSharp.

Does this stop you from using Cursor

Yes - Cursor is unusable

@ravirahman can you please help with this one?

We only support the netcoregdb debugger for C# debugging within Cursor. If the debugger isn’t working in the IDE, could you try using the command line variant?

If that still doesn’t work, then it’s likely that the debugger isn’t compatible with this particular project unfortunately.

Thanks for the answer! I don’t really understand what you mean by “command line variant”? Or question about switching debugger either, because all I have done was create WinForms project in VS and then try to run it in Cursor using the only extension I can find easily from the extensions store.

But I did understand the incompatible part. That is a bummer for sure, because WinForms is still quite much alive from Microsoft side and some things are so easy there to do compared anything else.

This topic was automatically closed 22 days after the last reply. New replies are no longer allowed.