我们在TFS构建的解决方案中添加了许多Office AddIn项目,现在它正在破碎。我们正在使用Visual Studio和TFS 2008(SP1)。已添加4个项目,每个项目针对以下每个目标......
构建日志报告以下内容......
C:\Program Files\MSBuild\Microsoft.VisualStudio.OfficeTools2.targets(116,9): error MSB4062: The "GenerateAndPersistAppInfoTask" task could not be loaded from the assembly Microsoft.VisualStudio.Tools.Applications.Hosting, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a. Could not load file or assembly 'Microsoft.VisualStudio.Tools.Applications.Hosting, Version=8.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified. Confirm that the <UsingTask> declaration is correct, and that the assembly and all its dependencies are available.
Microsoft.VisualStudio.Tools.Applications.Runtime.v9.0.dll存在于服务器上,并在GAC中正确安装。用于Office的Visual Studio工具(2005和3.0)也都已安装。 如果远程访问服务器并运行Visual Studio,我可以重新创建其中一个插件并成功编译它。
帮助,卡住了!
答案 0 :(得分:0)
原来我需要将Microsoft.VisualStudio.Tools.Applications.Hosting.dll安装到GAC。我已经安装了Microsoft.VisualStudio.Tools.Applications.Hosting.v9.0.dll,但这不是兼容版本。