1. Copy the project to a new project directory
  2. Open it and rebuild it to ensure it builds correctly.
  3. In solution explorer right click the solution > Rename
  4. In solution explorer right click the project  > Rename
  5. Below here may need updating….
  6. Rename the main project files to the new project name
  7. Open project by running Visual Studio and then opening the NewProjectName.vcproj file
  8. Expanding the project files tree, in Source Files delete the OldProjectName.cpp file and add the NewProjectName.cpp project file
  9. Delete the original Debug and Release folders.
  10. Menu > Build > Rebuild Solution and the project should compile.

If you rename the namespace you will need to update the RootNamespace property for the project.  Unlike for C# and VB this doesn't seem to be possible via the project properties, but can be done by closing the project, right click YourProjectName.vcproj and open with notepad.  Look for the <RootNamespace> entry and update it.

If you rename say the main window file (just right click and re-name) you will get a build error as you will need to update the include to it from the main project .cpp file.

USEFUL?
We benefit hugely from resources on the web so we decided we should try and give back some of our knowledge and resources to the community by opening up many of our company’s internal notes and libraries through mini sites like this. We hope you find the site helpful.
Please feel free to comment if you can add help to this page or point out issues and solutions you have found, but please note that we do not provide support on this site. If you need help with a problem please use one of the many online forums.