943,923 Members | Top Members by Rank

Ad:
  • C++ Discussion Thread
  • Unsolved
  • Views: 1424
  • C++ RSS
You are currently viewing page 1 of this multi-page discussion thread
Oct 24th, 2008
0

Cant compile single c++ file

Expand Post »
I have one *.cpp file but I cant it compile with MS VC++ ! How to compile signle .cpp file in VC++? Please help me!
Similar Threads
Reputation Points: 6
Solved Threads: 0
Newbie Poster
StephanJos is offline Offline
9 posts
since Oct 2008
Oct 24th, 2008
0

Re: Cant compile single c++ file

Under "Build", click "Build Solution", or just hit F7.

If there is no "Build" in the menu, then you need to create a project first. Click File->New->Project.
Last edited by Evan M; Oct 24th, 2008 at 2:42 pm.
Reputation Points: 11
Solved Threads: 5
Light Poster
Evan M is offline Offline
42 posts
since Sep 2007
Oct 24th, 2008
0

Re: Cant compile single c++ file

what project if I need single file (consule aplication)
Reputation Points: 6
Solved Threads: 0
Newbie Poster
StephanJos is offline Offline
9 posts
since Oct 2008
Oct 24th, 2008
0

Re: Cant compile single c++ file

You can work with a single file but it has to be in a project.
Why is that? You probably ask. Well you might add some other files later(resources, databasefiles, etc.) if you stay with one file OK, but it's handy if you have more files to keep them in one project.
Reputation Points: 2035
Solved Threads: 645
Senior Poster
ddanbe is offline Offline
3,740 posts
since Oct 2008
Oct 24th, 2008
0

Re: Cant compile single c++ file

What project I need to create for simple c++ consule program?
Reputation Points: 6
Solved Threads: 0
Newbie Poster
StephanJos is offline Offline
9 posts
since Oct 2008
Oct 24th, 2008
0

Re: Cant compile single c++ file

Select the "File" menu and select "New Project...".
A window opens.
Under the many options select Console Application.
Reputation Points: 2035
Solved Threads: 645
Senior Poster
ddanbe is offline Offline
3,740 posts
since Oct 2008
Oct 24th, 2008
0

Re: Cant compile single c++ file

Win32 Console Application.
Reputation Points: 11
Solved Threads: 5
Light Poster
Evan M is offline Offline
42 posts
since Sep 2007
Oct 24th, 2008
0

Re: Cant compile single c++ file

I created project but it shows:
->header files:
stdafx.h
targetver.h
->Source files:
stdafx.cpp
test2.cpp


Why so many files in project if I need compile 1 file and I dont need that files.. And I donkt know where to write my code in that stupid project..How can then I compile
Reputation Points: 6
Solved Threads: 0
Newbie Poster
StephanJos is offline Offline
9 posts
since Oct 2008
Oct 24th, 2008
0

Re: Cant compile single c++ file

After creating the Win32 Console Application project, there should be a window that says "Win32 Application Wizard". Click "next" and click the "Empty Project" checkbox.
Reputation Points: 11
Solved Threads: 5
Light Poster
Evan M is offline Offline
42 posts
since Sep 2007
Oct 24th, 2008
0

Re: Cant compile single c++ file

Thank you!
Reputation Points: 6
Solved Threads: 0
Newbie Poster
StephanJos is offline Offline
9 posts
since Oct 2008

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C++ Forum Timeline: C++ encryption
Next Thread in C++ Forum Timeline: synchronize computertime using internet





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC