Sunday, October 14, 2012

VS 2005 convert to VS 2010 - property pages

A client sent me their Visual Studio 2005 project. I have Visual Studio 2010 Express. I opened the project, and it offered to convert it. It failed miserably. First thing is, it couldn't handle the x64 configurations. So I opened the VS 2005 vcproj file, and I removed the x64 configurations. Yay!

It now opens the project, (reporting that conversion passed without errors). Except that it is lying. The property pages have converted as pretty much empty files. It has the XML header, but all of the property pages are empty.

Long story short, go to the command line, and use vcupdate on the original vcproj file. One problem I noticed was the SolutionDir wasn't available as you can't run vcupdate on an sln file. So in the command prompt, type:

set SolutionDir=(path of the project)

Then run vcupgrade on the vcproj file. Make sure the path is a fixed path and not relative to the vcproj file.

That does it, the property pages get converted properly!

No comments:

Post a Comment