错误 MSB4062:“GenerateAndPersistAppInfoTask”任务无法加载

发布于 2024-08-07 19:52:47 字数 1093 浏览 4 评论 0原文

我们已将许多 Office AddIn 项目添加到我们的 TFS 构建的解决方案中,现在它正在崩溃。我们使用 Visual Studio 和 TFS 2008 (SP1)。已添加 4 个项目,每个项目对应以下目标...

  • Word 2003
  • Word 2007
  • Excel 2003
  • Excel 2007

生成日志报告以下内容 ...

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 中。 Visual Studio Tools for Office(2005 和 3.0)也全部安装。 如果远程到服务器并运行 Visual Studio,我可以重新创建这些插件之一并成功编译它。

求助,卡住了!

We have added a number of Office AddIn projects to our TFS-built solution and now it's breaking. We are using Visual Studio and TFS 2008 (SP1). 4 projects have been added, one for each of the following targets...

  • Word 2003
  • Word 2007
  • Excel 2003
  • Excel 2007

The Build Log reports the following ...

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 exists on the server and is installed correctly in the GAC. Visual Studio Tools for Office (2005 & 3.0) are also all installed.
If remote onto the server and run Visual Studio I can re-create one of these addins and successfully compile it.

Help, stuck!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

合久必婚 2024-08-14 19:52:47

结果我需要将 Microsoft.VisualStudio.Tools.Applications.Hosting.dll 安装到 GAC。我已经安装了 Microsoft.VisualStudio.Tools.Applications.Hosting.v9.0.dll,但这不是兼容版本。

Turns out I needed Microsoft.VisualStudio.Tools.Applications.Hosting.dll installed to the GAC. I already had Microsoft.VisualStudio.Tools.Applications.Hosting.v9.0.dll installed, but this wasn't a compatible version.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文