Failed to execute command: ""C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\ResGen.exe" 的一个解决办法

最近在做wpf项目,期间下了一些源码参考,但是在build时经常遇到下面这种bug:

 

Error 2 Failed to execute command: ""C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\ResGen.exe" /useSourcePath
/r:C:\Windows\Microsoft.NET\Framework\v2.0.50727\mscorlib.dll "/r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework
\v3.0\PresentationCore.dll" "/r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.0\PresentationFramework.dll"
"/r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Core.dll" "/r:C:\Program Files (x86)\Reference
Assemblies\Microsoft\Framework\v3.5\System.Data.DataSetExtensions.dll" /r:C:\Windows\Microsoft.NET\Framework
\v2.0.50727\System.Data.dll /r:C:\Windows\Microsoft.NET\Framework\v2.0.50727\System.dll /r:C:\Windows\Microsoft.NET\Framework
\v2.0.50727\System.Xml.dll "/r:C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.5\System.Xml.Linq.dll" "/r:C:
\Program Files (x86)\Reference Assemblies\Microsoft\Framework\v3.0\WindowsBase.dll" /compile Properties\Resources.resx,obj
\Release\rotateButton.Properties.Resources.resources". D:\Documents\Visual Studio 2010\Projects\ntCtrlLibs\rotateButton\TRACKER
rotateButton

 

百度发现ms是因为“在64位的Windows 7下,用VS2010编译4.0以前的.Net项目会有问题”

下面是一种解决办法。本人试了下,没有成功....

gisoracle http://www.cnblogs.com/gisoracle/archive/2012/06/11/2544552.html

 

后来无意中在一个地方看到说:删除Properties文件夹下的Resources.resx这个文件就可以了。

本人试了下,竟然能用了....

 

有遇到同样问题的可以试试这个解决办法。

 

本人菜鸟一只,大神路过请轻喷。

posted @ 2013-12-13 17:07  Raven11647  阅读(1317)  评论(1编辑  收藏  举报