While testing the Visual Studio 2010 CTP went ahead and created a project, forgetting that the target version was in reality Visual Studio 2008. That said, since it was working just as it was required; found myself with the need to find a way to convert it backwards with as little re-work as possible.
Keep in mind that the Visual Studio 2010 CTP is still not the final release and things might change down the road, but for the moment the steps that worked for me are listed below.
· Open the .sln file corresponding to the Project to be converted with Notepad
· Locate the following line: Microsoft Visual Studio Solution File, Format Version 11.00
· Replace 11.00 with 10.00
· Locate the following line: # Visual Studio 10
· Replace 10 with 2008
· Save the File
· Delete the .cache files existing in the following paths:
o obj/debug
o obj/release
· Open the project with Visual Studio 2008
· Build the project with Visual Studio 2008
Thank you so much dude, i thougt i screwed up my entire project! Thx so much again!
ReplyDeleteWhen I try to open the porject file in 2008, I get an error message saying "Unable to read project file of type csproj.
ReplyDeleteFrom the provided information I do have a couple of things that come to mind:
ReplyDelete1- Either Visual Studio is not installed or not correctly installed
2- Visual Studio has not been installed with the C# project capabilities
Could you provide more details to be able to help you better?
Hey, thanks a lot. u are a life saver :)
ReplyDeleteThanks! VS2010 has become completely unusable has it keeps hanging on build and closing the (coded) application. though my .cache files where up one level. in obj/
ReplyDelete<3
Thank you!
ReplyDeleteThousands of Thanks :D my Assignments are due tomorrow and did it using VS2010 Premium(RTM) but later figured that its not working in 2008. The above conversion worked perfectly :)
ReplyDeleteMiles de gracias, has salvado mi vida xd
ReplyDeleteThanks so much, man!
ReplyDeleteAddition: After applying these changes i still had the same error (solution file is created in a newer version etc) when trying to open the project from the "recent projects menu". But by using file - open i could open the solution just fine
ReplyDeleteFantastic, thanks!
ReplyDeleteThanks, u help me a lot xD
ReplyDeleteMate you are great! Good on you ! :)
ReplyDeleteworked like a charm
ReplyDeleteTY
thanxxxxxxxxxx alot
ReplyDeletegod bluss you
It did work, of course a little debugging works are required. But finally, I get my job done. It is amazing! Thanks a lot.
ReplyDeletethx :)
ReplyDeleteThanks a lot. I have to submit my assignment in 20 minutes but just found out this kind of problem.
ReplyDeleteThanks for the solution
hey, can you help me?
ReplyDeleteI've changed the .sln file, but when I try reload my project the following message show up: "*.vbproj cannot be openned because its project type(.vbproj) is not supported by this version of application"
What should I do?
thanks
Renier,
ReplyDeleteTry opening only the project not the solution. Once the project is open, save the solution and overwrite the sln file.
Regards,
Doug Ortiz
Don't forget to check the .NET Framework settings in the *.vbproj file. The callout is something like...
ReplyDeleteProject DefaultTargets="Build" ToolsVersion="3.5" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"
I believe the default framework for 2010 is 4.0 and for 2008, 3.5.
Jim Mosher
Damn! this is awesome! thanks a lot!
ReplyDeleteThanks!
ReplyDeleteAwesome, now @ home where i have 2010, I can work on work projects where I only have 2008 and still open them in 2008. I created 2 sln files so I just open the correct one.
ReplyDeleteThanks!!
Seriously dude...This is a great help!!! keep it up..thanks
ReplyDeleteit works! thanks a lot
ReplyDeletethanks man seriously, it helped a lot,,,,,, but help me there's a problem it's asking for system.drawing version=4.0.0.0 and saying it can't find the specified field
ReplyDeletewhat should i do now ?
Anonymous,
ReplyDeleteRemove all references to the .Net 4.0 Framework in the project, that should take care of your problem.
Regards,
Doug Ortiz
cheers mate , it helps alot
ReplyDeletethks
ReplyDeleteYou totally saved my rear dude! Thanks!
ReplyDeletethanx man !
ReplyDeleteif any one having problem of framework then go to "csproj" and replace framework 4.0 with 3.5
and have fun
thanks dude. It worked
ReplyDeletethanks a lot dude....u saved my project...:)
ReplyDeleteDude!!Thanks Man.You are a life saver!
ReplyDeleteThanks!
ReplyDeleteAlso... I had an error in my config file.
<sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=4.0.0.0, Culture=neutral >
Changed:Version=2.0.0.0
You are awesome. I reverse your solution, And then open VS2008 file in my new VS2010. THIS REALLY WORKS. YOU just save my coming assignment.
ReplyDeleteGood finding, thanks a bunch. Astonishing that VS2008 can't try this simple trick automatically when attempting to open a solution with an incompatible version...
ReplyDeleteCheers mate, saved me a massive headache
ReplyDeletei'm facing prbl while running a project vs 2008 developed in 2010.showing error "cannot load file system.web .... 4.0.0.0" something like this...can anybody help me,wht to do?
ReplyDeletebipin,
ReplyDeleteFrom the description of the error message it sounds like you should check the target framework of the project solution.
Regards,
Doug Ortiz
Thanks but will it work for Visual Basic 2008
ReplyDeleteYes.
ReplyDeleteRegards,
Doug
cara vc me salvou velho , muito obrigado mesmo ,parabens pelo post
ReplyDeleteATT
Hugo Gomes
Esse linha de código deve se alterada em que arquivo:
ReplyDelete<sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=4.0.0.0,> Culture=neutral
Alterado: Version = 2.0.0.0
What do I do with the coding above? I need to open a vb 2010 file in vb 2008
ReplyDeleteAnonymous,
ReplyDeleteThe coding above is for the sln file.
you saved me big time. I owe you a beer.. :)
ReplyDeleteSandeepta
Thanks so much! Worked flawlessly.
ReplyDeleteDoug, i did everything as you mentioned..but still i am getting some error message..
ReplyDeleteCould not load file or assembly 'MyProject'(it's my project name) or one of its dependencies. This assembly is built by a runtime newer than the currently loaded runtime and cannot be loaded.
Nick,
ReplyDeleteThe error you are getting is because one of the dependencies, particularly an assembly was built in a newer version of Visual Studio. The project has been converted successfully but these dependencies are not being loaded and causing the project loading to fail.
Doug
I would recommend performing the conversion process to 2008 to these dependencies , that will resolve your issue.
ReplyDeleteTHANKS A LOT THIS INFORMATION REALLY SAVE MY TIME
ReplyDeleteTHANKS A LOT ONCE AGAIN
Hey I got the below error: Can any one help me with this??
ReplyDeleteUnable to read the project file:
The tools version "4.0" is unrecognized
Satya,
ReplyDeleteCheck carefully step #2, it seems you did not update it with the correct number.
Regards,
Doug Ortiz
Help me please.. i already followed your steps but i don't know what's going on..
ReplyDeletehere's the error msg..
wpfApp.csproj cannot be opened because its project type. (.csproj) is not supported by this version of visual studio
By the error that you have listed, it seems you are using either Web Matrix or a version of Visual Studio that does not support csproj. Check to see if your version of Visual Studio is correctly installed.
ReplyDeleteRegards,
Doug Ortiz
Works perfect, thanks!
ReplyDeleteThank so much
ReplyDelete