Reputation: 1168
Hi I created one sln using Visual studio 2012
, but my colleague asked me to convert them into Visual studio 2010
version for the team here use 2010 as standard, instead of creating a brand new 2010 sln/project and include all files from the previous 2012 sln/project, can I modify the 2012 sln/project file directly to make the conversion? Thanks!
Upvotes: 1
Views: 15295
Reputation: 395
If you are given a VS2012 C++ project, but you only have access to Visual Studio 2010. Then you can use the following method:
ps. If you are converting C++ projects from the newer Visual Studio 2013, then in Step 2, you also need to change the ToolsVersion to 4.0.
Upvotes: 2
Reputation: 622
We've managed to upgrade all of our existing Solutions and projects in-place by doing the following:
For each .sln file, modify the first 2 lines in the file from
Microsoft Visual Studio Solution File, Format Version 11.00 # Visual Studio 2012
(the version will be 9.00 or 10.00 depending on whether you're upgrading from VS2008 or 2010).
For every csproj file, change the ToolsVersion from 3.5 to 4.0 in this line:
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="4.0">
These solutions/projects now load as-is without any conversion, and build/run just fine.
Upvotes: 3
Reputation: 2261
I ran into problems converting a solution and for me (it was an MVC.net project)
The issue was solved by modifying the following keys: {AAB7808F-0E04-46AE-8EFC-46E4C81AC77D} {349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}
I took the project guids out of an existing 2010 mvc.net solution and dropped them into the project I was porting from 2012.
This was in addition to modifying the sln files with the version numbers and then having to manually change the framework versions (4.5 -> 4.0)
Upvotes: 0
Reputation: 63298
You only need the following,
Then all your teammates can use this new solution to open the projects.
If you are porting Visual C++ projects, please make sure you set platform toolkit to v100 in Visual Studio 2012, before adding the projects (.vcxproj) to Visual Studio 2010 solution.
Upvotes: 4