我使用x86平台目标编译了整个项目。当我将.exe和参考DLL复制到服务器上并从服务器cmd窗口运行.exe时,它工作正常。UNC路径和未处理的异常:C#中的System.BadImageFormatException
我们的要求是将exe和dll复制到某个网络路径上,并使用UNC路径在服务器上执行exe。当我使用UNC路径执行时,出现错误:
Unhandled Exception: System.BadImageFormatException: Could not load file or assembly 'XXXX, Version=3.0.10.19399, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format. File name: 'XXXX, Version=3.0.10.19399, Culture=neutral, PublicKeyToken=null'
WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. Note: There is some performance penalty associated with assembly bind failure logging. To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
有人可以帮忙吗?
当您启用大会绑定日志记录消息建议时会发生什么? – Dai