简体   繁体   English

如何将VC ++ 2010项目降级到VC ++ 2008?

[英]How to downgrade VC++ 2010 project to VC++ 2008?

This is a usual MFC project developed in VC++ 2010 but since my client does not have VC++ 2010, I need to downgrade to VC++ 2008. When I tried, I got "Cannot load the project due to a corrupt project file." 这是在VC ++ 2010中开发的常规MFC项目,但是由于我的客户端没有VC ++ 2010,因此我需要降级到VC ++2008。尝试时,出现“由于项目文件损坏而无法加载该项目”。

Is there any way to downgrade the project file? 有什么办法可以降级项目文件?

UPDATE: As people suggested, I created new project in VC 2008 and started from there. 更新:正如人们所建议的那样,我在VC 2008中创建了一个新项目,并从那里开始。 It took an hour to make it runnable so I can't complain. 它花了一个小时才能运行,所以我不能抱怨。 But of course, it was not copy-and-paste easy. 但是,当然,复制和粘贴并不容易。 I had to copy all include directories and libraries correctly. 我必须正确复制所有包含目录和库。 And had to delete unnecessary code parts that do not exist in 2008. One thing I can't still figure out is an error in rc file 并且不得不删除2008年不存在的不必要的代码部分。我仍然不知道的一件事是rc文件中的错误

RC2176 : old DIB in res\MyApp.ico; pass it through SDKPAINT 

It apparently can't recognize the icon format for some reason. 由于某种原因,它显然无法识别图标格式。 For now, I commented out that icon part. 现在,我注释掉了该图标部分。

The only way I know of is to create a new VC++ 2008 project and copy all of your VC++ 2010 files into it. 我知道的唯一方法是创建一个新的VC ++ 2008项目并将所有VC ++ 2010文件复制到其中。 If you drag/drop from Windows Explorer into the Solution Explorer in VS, it will add them to your project and copy them to your project folder. 如果从Windows资源管理器拖放到VS中的解决方案资源管理器中,它将把它们添加到您的项目中并将它们复制到您的项目文件夹中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM