我和视觉工作室有个问题。我从这里版本5.1.0.24运行VS 2013专业和已安装的TDS (),但是当我试图在visual下放弃一个新的TDS项目(在这个捕获中名为TDSMaster )时,我会得到这个错误。

我正在运行Visual 2013 pro,windows 7 pro。我已经安装了VS的其他版本(2012、2013、2015),但在安装VS 2013 pro之前将其卸载。
有人要帮忙吗?
发布于 2016-01-08 09:20:10
我终于找到了解决方案,所以我分享它,以防有人有同样的问题有一天。问题是,当我卸载VS 2015社区时,出于某种原因,它没有删除registery中的一个键,在VS输出中,我得到了这个异常(但它不是每次我尝试创建porject时都显示出来的,只是有时候)。
Exception MSBuildToolsPath is not specified for the ToolsVersion "14.0" defined at "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSBuild\ToolsVersions\14.0", or the value specified evaluates to the empty string. (InvalidToolsetDefinitionException):
at Microsoft.Build.BuildEngine.InvalidToolsetDefinitionException.Throw(Exception innerException, String resourceName, Object[] args)
at Microsoft.Build.BuildEngine.ToolsetReader.ReadToolset(PropertyDefinition toolsVersion, BuildPropertyGroup globalProperties, BuildPropertyGroup initialProperties, Boolean accumulateProperties)
at Microsoft.Build.BuildEngine.ToolsetReader.ReadEachToolset(ToolsetCollection toolsets, BuildPropertyGroup globalProperties, BuildPropertyGroup initialProperties, Boolean accumulateProperties)
at Microsoft.Build.BuildEngine.ToolsetReader.ReadToolsets(ToolsetCollection toolsets, BuildPropertyGroup globalProperties, BuildPropertyGroup initialProperties, Boolean accumulateProperties)
at Microsoft.Build.BuildEngine.ToolsetReader.ReadAllToolsets(ToolsetCollection toolsets, ToolsetRegistryReader registryReader, ToolsetConfigurationReader configurationReader, BuildPropertyGroup globalProperties, BuildPropertyGroup initialProperties, ToolsetDefinitionLocations locations)
at Microsoft.Build.BuildEngine.Engine.PopulateToolsetStateMap(ToolsetDefinitionLocations locations)
at Microsoft.Build.BuildEngine.Engine..ctor(Int32 numberOfCpus, Boolean isChildNode, Int32 parentNodeId, String localNodeProviderParameters, BuildPropertyGroup globalProperties, ToolsetDefinitionLocations locations)
at Microsoft.Build.BuildEngine.Engine.get_GlobalEngine()
at Microsoft.VisualStudio.Package.Utilities.InitializeMsBuildEngine(Engine existingEngine, IServiceProvider serviceProvider)
at HedgehogDevelopment.SitecoreProject.VSIP.SitecoreProjectPackage.Initialize()所以我所要做的就是删除注册表中的密钥,就像这里解释的那样。
我按照理查德·西尔的建议编辑我的问题
公开登记(regedit)
导航到HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSBuild (OS 32位)或HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSBuild (64位)
在进一步备份此注册键之前(选择MSBuild键,然后将->导出文件)
展开ToolsVersions在MSBuild下,您应该看到14.0出现在ToolsVersions下,而不是在MSBuild下面,删除这个键
如果您有VS正在运行,则应该重新启动它。
https://stackoverflow.com/questions/34666210
复制相似问题