【发布时间】:2021-11-02 21:27:07
【问题描述】:
当我在其他计算机上运行我的 WPF 应用程序时,它会抛出这个错误:
Description: A .NET Core application failed.
Application: program.exe
Path: C:\fakepath\program.exe
Message: A fatal error occurred. The required library hostfxr.dll could not be found.
If this is a self-contained application, that library should exist in
[C:\fakepath\].
If this is a framework-dependent application, install the runtime in the global location [C:\Program
Files\dotnet] or use the DOTNET_ROOT environment variable to specify the runtime location or
register the runtime location in [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x64\InstallLocation].
添加库运行时 3.1.0 对我有帮助。
【问题讨论】:
-
我在 Azure 上的测试项目中遇到了这个问题。我必须在管道的开头添加一个安装运行时的步骤。
标签: .net-core