I'm taking a C++ class and have a couple of questions to make my life a little easier. We do a lot of short exercises where we have to write code from scratch. I'm using Visual Studio 2010. Every time when I begin a new project, I have to make the same changes to the beginning code that VS initiates for me (like erasing the line "Console::WriteLine(L"Hello World");". Is there a way that I can create my own standard beginning lines of code to short cut this a bit?
Also, I use different computers, which makes storage of the code a little problematic. Ideally, I'd like to save my code to a thumb drive. When I do this, however, if I try to open the project on a different machine, it doesn't work (can't remember the error message right now, but can recreate it if needed). What do I need to do to allow me to save my code to a thumb drive in a way that I can access it on different machines?
Can anybody help me with these two questions? Thanks!
You should just make an empty project and type the beginning code yourself. AFAIK, VC++ doesn't have a generic Hello World project for standard C++, but you could copy & paste any number of them from the internet, or create a file you copy in for individual projects.
You should go into the project folder and save the source and header (cpp and hpp) files you've created. Those are the code files; the rest are project information VC++ uses, the executables, etc.