gpt4 book ai didi

c# - 应用程序启动失败,因为它的并行配置不正确

转载 作者:IT王子 更新时间:2023-10-29 04:36:46 25 4
gpt4 key购买 nike

Unhandled Exception: System.IO.FileLoadException: Could not load file or assembl y 'TheLibrary, Version=1.2.3905.36284, Culture=neutral, PublicKeyToken=14 04827c3a8f2601' or one of its dependencies. The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log for more detail. (Exception from HRESULT: 0x800736B1) File name: 'TheLibrary, Version=1.2.3905.36284, Culture=neutral, PublicKe yToken=1404827c3a8f2601' ---> System.Runtime.InteropServices.COMException (0x800 736B1): The application has failed to start because its side-by-side configurati on is incorrect. Please see the application event log for more detail. (Exceptio n from HRESULT: 0x800736B1)

当我查看事件日志时,出现此错误。

Activation context generation failed for "C:\project\Debug\MyLibrary.dll". Dependent Assembly Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8" could not be found. Please use sxstrace.exe for detailed diagnosis.

我使用 sxstrace 记录错误,结果如下:

================= Begin Activation Context Generation. Input Parameter: Flags = 0 ProcessorArchitecture = x86 CultureFallBacks = en-US;en ManifestPath = C:\Windows\system32\cmd.exe AssemblyDirectory = C:\Windows\system32\ Application Config File = ----------------- INFO: Parsing Manifest File C:\Windows\system32\cmd.exe. INFO: Manifest Definition Identity is Microsoft.Windows.FileSystem.CMD,processorArchitecture="x86",type="win32",version="5.1.0.0". INFO: Activation Context generation succeeded. End Activation Context Generation.

================= Begin Activation Context Generation. Input Parameter: Flags = 0 ProcessorArchitecture = x86 CultureFallBacks = en-US;en ManifestPath = C:\Debug\TheLibrary.dll AssemblyDirectory = C:\Debug\ Application Config File = ----------------- INFO: Parsing Manifest File C:\Debug\TheLibrary.dll. INFO: Manifest Definition Identity is (null). INFO: Reference: Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8" INFO: Resolving reference Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8". INFO: Resolving reference for ProcessorArchitecture x86. INFO: Resolving reference for culture Neutral. INFO: Applying Binding Policy. INFO: No publisher policy found. INFO: No binding policy redirect found. INFO: Begin assembly probing. INFO: Did not find the assembly in WinSxS. INFO: Attempt to probe manifest at C:\Windows\assembly\GAC_32\Microsoft.VC90.DebugCRT\9.0.21022.8__1fc8b3b9a1e18e3b\Microsoft.VC90.DebugCRT.DLL. INFO: Attempt to probe manifest at C:\Debug\Microsoft.VC90.DebugCRT.DLL. INFO: Attempt to probe manifest at C:\Debug\Microsoft.VC90.DebugCRT.MANIFEST. INFO: Attempt to probe manifest at C:\Debug\Microsoft.VC90.DebugCRT\Microsoft.VC90.DebugCRT.DLL. INFO: Attempt to probe manifest at C:\Debug\Microsoft.VC90.DebugCRT\Microsoft.VC90.DebugCRT.MANIFEST. INFO: Did not find manifest for culture Neutral. INFO: End assembly probing. ERROR: Cannot resolve reference Microsoft.VC90.DebugCRT,processorArchitecture="x86",publicKeyToken="1fc8b3b9a1e18e3b",type="win32",version="9.0.21022.8". ERROR: Activation Context generation failed. End Activation Context Generation.

无法解析引用 Microsoft.VC90.DebugCRT,processorArchitecture=...

有什么想法吗?

最佳答案

我们刚刚遇到了这个完全相同的错误,但与错误相比,原因是如此具有误导性,希望它值得在此处添加,因为它在谷歌上名列前茅...

启动 Windows 服务时出现“应用程序启动失败,因为其并排配置不正确”错误。在我们的实例中,这是由服务 application.config xml 文件无效引起的 - 有人手动编辑它并粘贴了一个额外的结束标记。对此进行修改解决了“不以任何方式相关”的错误消息。

检查这一点的最快方法是将 xml 文件粘贴到网络上许多免费的在线 xml 验证器之一。

关于c# - 应用程序启动失败,因为它的并行配置不正确,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3961742/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com