Default project in Visual C++ 2008
In Visual C+开发者_JAVA百科+ 2008 ( Professional Edition )it is impossible to create default project for a .cpp file. Sometimes it is inconvenient. Is there an edition of Visual C++ 2008 which allows it?
It's available, assuming you've already written the .cpp file. Use File + New + Project From Existing Code. You'll get a point-and-click wizard with a bunch of questions that need to be answered.
I reckon you'll use this a few times, then discover it is just simpler to start a new project from scratch with the Win32 Console Application template. Just add your .cpp to the project's Source Files folder.
Why you can't do this?
You can normally create Win32 C++ project and have with this .cpp file.
You mean you don't want to create a solution each time? There's no getting around this. It can be useful to create a Sandbox solution and just fill that up with .cpp files to throw your ideas around on.
精彩评论