惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

G
Google Developers Blog
宝玉的分享
宝玉的分享
月光博客
月光博客
B
Blog
云风的 BLOG
云风的 BLOG
Google DeepMind News
Google DeepMind News
Engineering at Meta
Engineering at Meta
aimingoo的专栏
aimingoo的专栏
N
Netflix TechBlog - Medium
博客园_首页
GbyAI
GbyAI
人人都是产品经理
人人都是产品经理
A
About on SuperTechFans
Y
Y Combinator Blog
L
LangChain Blog
有赞技术团队
有赞技术团队
D
Docker
爱范儿
爱范儿
博客园 - 司徒正美
H
Hackread – Cybersecurity News, Data Breaches, AI and More
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
酷 壳 – CoolShell
酷 壳 – CoolShell
Microsoft Security Blog
Microsoft Security Blog
D
DataBreaches.Net

博客园 - Xia.CJ

C# 委托 node.js中连接mongodb(Please ensure that you set the default write...)解决办法 node.js api解读之file system模块 Node.js小技巧 在windows上安装新版node.js-node.js学习笔记 Asp.Net MVC部暑托管服务器iis7提示403错误解决方法 mvc3中使用unobtrusive时,ajax更新加载页面后验证失效解决方法 ashx中使用HttpContext.Current.Session ,出现未将对象引用设置到实例上 搜索引擎(google/百度)高级指令 在mvc3中使用uploadify上传组件User.isAuthenticated等于false解决方法 MVC中用Html.RenderPartial还是Html.RenderAction或者Html.Partial-Xia.CJ 在_Layout使用Html.RenderAction的问题-MVC3(Razor)问题 Javascript数组(array)操作 序列化类型 System.Data.Entity.DynamicProxies 的对象时检测到循环引用 entity framework(EF)_code first复杂类型(Complex Types)问题 entity framework多对多关系查询 JQuery获取checkbox值,checkbox全选,操作checkbox JQuery操作Select JQuery动态创建DOM、表单
无法删除此对象,因为未在 ObjectStateManager 中找到它-enti...
Xia.CJ · 2012-04-19 · via 博客园 - Xia.CJ

无法删除此对象,因为未在 ObjectStateManager 中找到它-entity framework删除时

把删除改为

  db.Entry<User>(entity).State = EntityState.Deleted;
            return db.SaveChanges();

就好啦

posted @ 2012-04-19 16:32  Xia.CJ  阅读(1827)  评论(2)    收藏  举报