当前位置: 移动技术网 > IT编程>开发语言>.net > Could not load file or assembly 'XXX' or one of its dependen

Could not load file or assembly 'XXX' or one of its dependen

2020年04月17日  | 移动技术网IT编程  | 我要评论

霸道异界,广州论坛大全,联想t410i

当在IIS 中发布.net的web应用时,

出现错误:

Server Error in '/' Application.

Could not load file or assembly 'XXX' or one of its dependencies. 试图加载格式不正确的程序。

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. 
Exception Details: System.BadImageFormatException: Could not load file or assembly 'Credit.RatingApi' or one of its dependencies. 试图加载格式不正确的程序。

......


查找后判断是应用程序链接池 Application Pool调用的dll文件出现了错误,多是在于64位平台调用32位的dll引起的。

解决方式 : 找到发布的iis站点应用使用的应用程序池 Application Pool,点开高级设置->将"Enable 32-bit applications" 项目选择为true,兼容32位应用程序。

如对本文有疑问,请在下面进行留言讨论,广大热心网友会与你互动!! 点击进行留言回复

相关文章:

验证码:
移动技术网