user5464440
user5464440

Reputation:

Visual Studio 2015 hangs on F5 or produces blank cmd window on ctrl+F5

I was having some trouble writing a really basic C++ program in Visual studio, as when I press F5 the mouse changes to the "loading" icon but nothing happens, or if I press ctrl+F5 it'll say "This project is out of date" and lists below this "projectname - Debug Win32". Upon allowing it to build, a command window pops up with nothing in it except a blinking underscore.

It's nothing code-related, this is only a basic C++ command line program. I even tested it with a "hello world" copied directly from Accelerated C++ so there's no way there's a problem with the code.

Upon checking task manager, there are three .exe files with the name of the program. Not all of them can be terminated. You can press end process, and it won't give you an error, but they don't disappear. There's also three conhost.exe (console window host - I'm presuming it's related) processes, which have the same thing.

If you attempt to ctrl+F5 or F5 after the initial attempt, it says there were build errors - it cant access the .exe for writing since there's an instance already open.

This occurs on a fresh install of VS Community 2015 with the Visual C++ install options ticked.

Upvotes: 1

Views: 618

Answers (2)

Gordonc1993
Gordonc1993

Reputation: 11

Are you using Avast! antivirus? If you are, try disabling it. Me and a friend actually had the exact same problem, and it was avast somehow conflicting with it.

EDIT: I found the actual problem. It's avast! DeepScreen. Turn that off under the settings. That breaks literally everything you create (Visual Studio, Xilinx, etc).

Upvotes: 1

Nick
Nick

Reputation: 38

Spectre1235,

I had literally the exact same problem where my code would not run, it gave the 3 .exe files that could not be terminated (other than by restarting the computer), and I knew there was nothing wrong with my code. You also could not CTRL+C out of the window, but you could exit it by pressing the red X. I just found the solution. I had been wanting to know for at least a week, and I believe this is your problem. Disable Avast! Antivirus (if you have it), or the equivalent antivirus, and then try running your code. Best of luck!

-Nick

Upvotes: 1

Related Questions