如何将VS 2005 sln升级到VS 2010 sln?错误转换 [英] How to Upgrade a VS 2005 sln to a VS 2010 sln? Error converting

查看:294
本文介绍了如何将VS 2005 sln升级到VS 2010 sln?错误转换的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好

我已经在VS 2010和TFS 2010上重新安装了2K8R2.我已经找到了一个旧的VS 2005项目,我想将其转换并添加到TFS中,但是当我使用VS 2010打开时,它可以t进行转换:

I I've got a fresh install of 2K8R2 with VS 2010 and TFS 2010.  I've tracked down an old VS 2005 project I want to convert and add to TFS but when I open with VS 2010 it can't convert it:

 

转换报告-SortString \ SortString.csproj:项目文件已成功备份为E:\ System \ My Documents All \ mdepouw \ Visual Studio 2005 \ Projects \ SortString \ Backup \ SortString \ SortString.csproj,您的项目面向.NET Framework 2.0或3.0.如果 如果您的项目使用需要更新的.NET Framework的程序集,则您的项目将无法生成.您可以通过单击项目菜单上的属性",然后在".NET Framework"下拉框中选择一个新版本来更改.NET Framework版本. (在 Visual Basic,通过单击高级编译器选项..."按钮,位于编译"选项卡上.)

Conversion Report - SortString\SortString.csproj: Project file successfully backed up as E:\System\My Documents All\mdepouw\Visual Studio 2005\Projects\SortString\Backup\SortString\SortString.csproj Your project is targeting .NET Framework 2.0 or 3.0. If your project uses assemblies requiring a newer .NET Framework, your project will fail to build. You can change the .NET Framework version by clicking Properties on the project menu and then selecting a new version in the '.NET Framework' dropdown box. (In Visual Basic, this is located on the Compile tab by clicking the 'Advanced Compiler Options...' button.)

无法保存转换后的项目文件.

Unable to save converted project file.

 

也许我看到了这个原因,因为我没有安装.Net 2.0?我知道我已经安装了.Net 4.0和.Net 3.5 SP1.

Maybe I'm seeing this cause I don't have .Net 2.0 installed?  I know I've got .Net 4.0 and .Net 3.5 SP1 installed.

如何打开项目属性并在无法打开项目的情况下进行更改?

How do I open the project properties and change it if I can't open the project?

推荐答案

我认为最简单的方法就是安装2.0/3.5Sp1框架.在我看来,Microsoft现在终于针对较旧的框架做了非常出色的工作(当他们发布Visual Studio.Net 2002时,我真的很讨厌这些______________). 制作.Net 1.0应用程序,然后2003版本只能制作1.1版本.随着时间的推移,它变得越来越好,随着2010年的发展,它变得越来越好!)

I think the easierst way would be to install the 2.0 / 3.5Sp1 Frameworks, too. In my eyes Microsoft finally did a very good work with targeting older Frameworks now (I really hated all this ____ when they published the Visual Studio.Net 2002 that could only make .Net 1.0 Applications and then the 2003 version could only make 1.1 ones ... And it got better and better with the time and with 2010 it got great!)

另一种方法是手动编辑项目文件(.csproj).在其中找到TargetFrameworkVersion.因此,您可以将其更改为:
< TargetFrameworkVersion> v4.0</TargetFrameworkVersion>

Another way could be to manually edit the project files (.csproj). In there you find the TargetFrameworkVersion. So you could change it to something like:
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>

项目文件是一个简单的XML文件,并且与MSBuild系统一起记录在文档中:
http://msdn.microsoft.com/en-us/library/0k6kkbsd.aspx

The project file is a simply XML file and it is documented together with the MSBuild system:
http://msdn.microsoft.com/en-us/library/0k6kkbsd.aspx

我希望我能提供帮助.

以诚挚的问候,

Konrad


这篇关于如何将VS 2005 sln升级到VS 2010 sln?错误转换的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆