First C++ program will not not execute
Hello.
I am using MS Visual C++6 Standard Edition, and MSDN 2000 on Windows XP.
Iâm working on the first example in the first chapter of Ivor Horton's 98 reprint, Beginning VC++6.
The program will not execute.
The following is the process that I have followed.
Creating a new project:
File-Newâ¦
In Project tab, Iâve selected, Win32 Console Application. Then entered the project name, and directed the location to my flash drive, k:\TrialRun, and clicked OK.
Next window selection is, Empty Project. Then finish, and OK.
Entering The first program:
File-Newâ¦
In file tab, Iâve selected C++ Source File, and unchecked the add new project selection. Clicked OK.
I write the program into the text window, and save it as TrialRun.cpp1.
The book says to use extension cpp, but it doesnât work. The system shows cpp1, which does.
Then I add a source file to the project, by right clicking and selecting, insert file into project.
I press F7, and it is built without flaw.
Everything goes smooth, until executing the program.
Result is:
K:\TrialRun\Debug\TrialRun.exe
This file does not exist. Do you want to build it?
Yes
Result: Cannot execute program.
I have also used the default location on the local hard drive for this project with the same result.
What am I doing wrong?
Thank you.
Dave
|