Red x form window, but I can not find the error notification

I use OpenTK GLControl (winforms. Open OpenGL control) to draw some things using opengl. The problem that I am currently facing is that I get a big red cross or x in the form of the window where the control is located, and it is completely impossible to debug, because I did not find a way to find out where the error occurs.

I do not see error / exception messages. I used to have the same problems with XNA, although I refused to use it for other reasons.

Maybe I missed something. Is there a window somewhere in Visual Studio that I can open and see these errors?

Windows that automatically open during debug mode are locales and a call stack. And they are completely empty.

+5
source share
2 answers

You can try to break all exceptions - a break in CLR exceptions . (Control / Alt + E to open the dialog box, then check the "Exclude common languages" box).

As you debug, it should stop where the error occurred.

If you can't find anything, you can see something by catching a generic AppDomain or Threading exception - details here

+5
source

The red x in the window shape design is due to an error in your paint code. To debug this:

  • open the solution in another instance of Visual Studio
  • Debugging a menu> Attach to a process ...
  • select devenv.exe

, .

0

All Articles