pgay
pgay

Reputation: 85

How to create multiple versions of one project in Visual C++ Express 2010

I wish to create several small programs for the sake of testing and experimentation using an external library (SDL in this case). It is a bit of a tedious process to set everything up, so I would prefer not to have to do it repeatedly.

I would like to know if there is an easy way to either:

  1. create a template that I can apply every time I wish to start a new project, such that the relevant include directories, etc. have already been added, or
  2. copy/create a revision of an existing project so that it changes its name/target directories, etc. automatically, allowing me to work with several versions simultaneously.

Upvotes: 1

Views: 245

Answers (1)

Martin Beckett
Martin Beckett

Reputation: 96177

I don't know if you can set templates in vs-express buyt copying projects in a solution is easy.

  1. Invent a solution name like foobar (do not use words likely to appear in a project file!)
  2. Create a project based on foobar and add to a solution.
  3. Copy foobar subdir to foobar2 (this obviously can be any name you want)
  4. In foobar2 edit 'foobar.vcxproj' and replace all 'foobar' with 'foobar2' - this assumes that foobar.cpp is foobar2.cpp in the 2nd project - if it isn't, simpyl don't replace the .cpp entries.
  5. Add foobar2 to the solution inside the IDE

Upvotes: 1

Related Questions