2

When I try to run my C++ codes using the start without debugging option in Microsoft Visual Studio, I get a blank window. I don't know why this is happening. I posted a screenshot of what has been happening anytime I try to run anything using the 'start without debugging' option. Any help would be appreciated

enter image description here

The Apache
  • 1,076
  • 11
  • 28
  • 1
    Check answer for [this](http://stackoverflow.com/questions/33690697/running-my-c-code-in-visual-studio-gives-me-a-blank-cmd) question :) – Konrad 'Zegis' Nov 20 '15 at 11:09

1 Answers1

0

First BUILD the application in Visual Studio. Then run the application using start without debugging.

Also, try to include system("PAUSE") in the code.

So, your code should be

int main()
{
  cout<<"Hello world!"<<endl;
  system("PAUSE");
  return 0;
}
The Apache
  • 1,076
  • 11
  • 28
  • I did build the application. When I try to run the program, however, using start without debugging I get a blank window as you have seen in the picture. (Hello World does not show up) I changed the code to the one you have provided and it does not change anything. Any further help is appreciated! – Confused Duck Nov 20 '15 at 11:05
  • Please make sure if the application is built. Because when you see the exe path on the window, it shows the `cmd.exe` and not the application's exe you have created. – The Apache Nov 20 '15 at 11:20
  • How did you build your application and are you sure that there aren't any errors? – The Apache Nov 20 '15 at 11:21