小编par*_*896的帖子

在.NET 4的生成过程中找不到LC.exe文件

迁移到.net 4.0时出现问题,在尝试构建时出现以下错误.

 C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\Microsoft.Common.targets(1917,9): 
  error MSB3086: Task could not find "LC.exe" using the SdkToolsPath "" or the 
  registry key "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v7.0A".

 Make sure the SdkToolsPath is set and the tool exists in the correct processor 
 specific location under the SdkToolsPath and that the Microsoft Windows SDK is
 installed 

 External Program Failed: C:\windows\microsoft.net\framework\v4.0.30319\MSBuild.exe
 (return code was 1)
Run Code Online (Sandbox Code Playgroud)

最新版本的microsoft windows sdk安装在机器上,但版本是v7.1.为了解决这个问题,我将以下几点放在注册表项中

   HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Microsoft SDKs\Windows\v7.0A\InstallationFolder 
 to C:\Program Files\Microsoft SDKs\Windows\v7.1\. 
Run Code Online (Sandbox Code Playgroud)

这工作有点但我觉得有点脏将7.0A注册表项指向7.1安装.有没有人有更好的解决方案来解决这个问题?

c#

10
推荐指数
1
解决办法
2万
查看次数

标签 统计

c# ×1