Create a project: File & gt; New & gt; Project … & gt; Empty Project
Create a file: File & gt; New & gt; File .. & gt; C++ File
I am writing a standard “Hello, world!”
# include & lt; iostream & gt;
#include & lt; cstdlib & gt;
using namespace std;
int main ()
{
cout & lt; & lt; "Hello, world!" & lt; & lt; endl;
system ("pause");
return 0;
}
Press ctrl + f5. Construction is in progress, there are no errors in the code, but the error “cannot start the program” path to exe file “pops up” The specified file cannot be found.
There is no exe file on this path, it is not even created.
I would appreciate your help.
Answer 1, authority 100%
You need not just create a file, but create and add it to the project. This is done this way, in the solution explorer, right-click on Source Files and select Add->New Item. If you have already created a file, as now, then select Add- & gt; Existing Item there and select your file