类型或名称空间名称"Core"在名称空间中不存在 [英] The type or namespace name 'Core' does not exist in the namespace

查看:133
本文介绍了类型或名称空间名称"Core"在名称空间中不存在的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

调试项目时遇到此类错误 我已经有EntityFramework.dllSystem.Core.dllSystem.Data.Entity,但仍未引用Core.

I encounter this kind of error when I debug a project I already have EntityFramework.dll, System.Core.dll, System.Data.Entity but still Core is not referenced.

有人可以帮助我吗?

我在此行中有错误

using System.Data.Entity.Core.Objects;

这是错误:

名称空间"System.Data.Entity"中不存在类型或名称空间名称"Core"(您是否缺少程序集引用?)

The type or namespace name 'Core' does not exist in the namespace 'System.Data.Entity' (are you missing an assembly reference?)

推荐答案

Enrique,当我开始在桌面上打开通常在VM上打开的项目时,出现了这个问题. Masoud的回答没有帮助...我认为他没有阅读您的原始帖子.

Enrique, I had this problem crop up when I started opening a project on my desktop that I had normally been opening on my VM. Masoud's answer is not helpful... I don't think he read your original post.

我为清除此编译错误所做的是打开NuGet程序包管理器并安装可用于EntityFramework的更新.我在项目中安装了6.1.1版,然后升级到6.1.3.我本来应该没有错误,但是升级该版本似乎会使它松动,因为在那之后我开始编译就很好了.

What I did to clear this compile error up was to open NuGet package manager and install the update that was available for EntityFramework. I had version 6.1.1 installed in the project and I upgraded to 6.1.3. I should not have had the error to start with, but upgrading the version appeared to jiggle whatever it was loose because I started compiling fine after that.

这篇关于类型或名称空间名称"Core"在名称空间中不存在的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆