相关疑难解决方法(0)

加载EntityFramework 4.3.1时出错

我用C#创建了一个MVC应用程序.我在我的解决方案中创建了一个名为PhoneDomain的新项目.这样做的目的是将我的数据和域层与实际问题分开.我右键单击该项目并转到"添加库包参考",我尝试添加EntityFramework包(版本4.3.1).它说" Operation Failed"" This package contains an init.ps1 file and needs to be installed from the Package Manager Console".

所以我在Visual Studio中打开了Package Manager控制台,并在控制台窗口中输入以下内容: install-package EntityFramework -project PhoneDomain

几秒钟后,它安装了包裹并说 Successfully added 'EntityFramework 4.3.1' to PhoneDomain

问题是,当我运行我的应用程序时,我收到以下错误消息: Could not load file or assembly 'EntityFramework, Version=4.3.1.0, Culture=neutral' or one of its dependencies. The system cannot find the file specified.

PhoneDomain中的引用肯定在那里,Copy Local属性设置为True.

谁能告诉我这里发生了什么?

c# ninject entity-framework-4.1 asp.net-mvc-3

9
推荐指数
1
解决办法
6908
查看次数

标签 统计

asp.net-mvc-3 ×1

c# ×1

entity-framework-4.1 ×1

ninject ×1