No window showing when building and running a C# MonoGame project


I've been working on a C# MonoGame project for a few days now and so far it has been building and running fine. I left it alone for a while and, when I came back, the window would no longer display (running as a console application displays a blank console window, but not the application itself).

I don't think it's due to the code itself because the issue started happening without any changes to it.

When building, the program exits with code -1, as shown below in the output:

The program '[12460] Gearworks Physics Engine.exe' has exited with code -1 (0xffffffff).

Note that building the program gives no errors, warnings, or messages.

I realise there are a lot of posts related to "exited with code _" and I have seen some with code -1, but they weren't very helpful to my situation, so I've decided to post my own question instead. Let me know if there's any other information needed to help!

asked on Stack Overflow Apr 10, 2021 by jackbennett. • edited Apr 10, 2021 by jackbennett.

1 Answer


Looks like I've solved it myself - I simply needed to update Visual Studio to the latest version, which I was apparently not using. Once I did that, all programs worked again.

answered on Stack Overflow Apr 11, 2021 by jackbennett.

User contributions licensed under CC BY-SA 3.0