asp.net - 加载共享类库时出错

我有一个ASP.NET网站/WPF/Windows Phone应用程序,它们都使用三个链接的项目。在数据项目(Myproject.DAL)中,我使用对System.Data.SQLiteICSharpCode.SharpZipLib的引用。后者似乎是为VS中的运行时版本2.0编译的,即使我下载了4.0版本(也许是我的误解)。

当我尝试加载ASP.NET 4站点时,出现错误:

Could not load file or assembly 'ChickenPing.DAL' or one of its dependencies. An attempt was made to load a program with an incorrect format.

我记得以前曾遇到过这个问题,它是由System.Data.SQLite库(一个x86二进制文件)引起的。我已经更新,这绝对不是原因。所有项目均设置为以.NET 4 x86运行。有什么办法可以找出造成这种情况的实际原因?我猜测一定是某个地方的问题DLL,但是MSBuild似乎没有报告任何问题。

尽管打开了Fusion日志记录,但我得到的唯一一个神秘错误是:
=== Pre-bind state information ===
LOG: User = IIS APPPOOL\CP
LOG: DisplayName = ChickenPing.DAL
 (Partial)
WRN: Partial binding information was supplied for an assembly:
WRN: Assembly Name: ChickenPing.DAL | Domain ID: 9
WRN: A partial bind occurs when only part of the assembly display name is provided.
WRN: This might result in the binder loading an incorrect assembly.
WRN: It is recommended to provide a fully specified textual identity for the assembly,
WRN: that consists of the simple name, version, culture, and public key token.
WRN: See whitepaper http://go.microsoft.com/fwlink/?LinkId=109270 for more information and common solutions to this issue.
LOG: Appbase = file:///C:/Users/echilon/Documents/CP/
LOG: Initial PrivatePath = C:\Users\echilon\Documents\CP\bin
Calling assembly : (Unknown).
===
LOG: This bind starts in default load context.
LOG: Using application configuration file: C:\Users\echilon\Documents\CP\web.config
LOG: Using host configuration file: C:\Windows\Microsoft.NET\Framework64\v4.0.30319\aspnet.config
LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework64\v4.0.30319\config\machine.config.
LOG: Policy not being applied to reference at this time (private, custom, partial, or location-based assembly bind).
LOG: Attempting download of new URL file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/Temporary ASP.NET Files/root/7bfa5a6e/c6574e91/ChickenPing.DAL.DLL.
LOG: Attempting download of new URL file:///C:/Windows/Microsoft.NET/Framework64/v4.0.30319/Temporary ASP.NET Files/root/7bfa5a6e/c6574e91/ChickenPing.DAL/ChickenPing.DAL.DLL.
LOG: Attempting download of new URL file:///C:/Users/echilon/Documents/CP/bin/ChickenPing.DAL.DLL.
ERR: Failed to complete setup of assembly (hr = 0x8007000b). Probing terminated.

确实并不能提供太多洞察力。

最佳答案

原来这是一个设置-应用程序池设置的“高级设置”部分中的“启用32位应用程序”。

https://stackoverflow.com/questions/8477698/

相关文章:

iphone - 编译我的应用程序没有错误,但是在设备上编译时挂起

java - 复选框编译错误

.net - 错误: “Expression must have class type” C++/C

java - 即使定义了类和参数,Java也找不到符号错误?

android - Dalvik格式失败,在ServerAssistant上出现错误1

android - Android Intent使用情况(Call_action和new_task_

c++ - C++/LabVIEW互操作: error extracting data from L

C++ - 清理后 Unresolved external symbol 错误

visual-studio-2010 - 未注册库时,无法使用引用的TLB编译.NET应用程序

ios - Amazon IOS SDK : compiler warnings - ARC iss