ManyToMany_Edit.ascx:
System.Data.Objects.ObjectContext' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
Cannot implicitly convert type 'System.Data.Objects.ObjectContext' to System.Data.Entity.Core.Objects.ObjectContext'
代码错误:
ds.ContextCreated += (_, ctxCreatedEnventArgs) => ObjectContext = ctxCreatedEnventArgs.Context;
注意:我完成了http://msdn.microsoft.com/en-US/data/upgradeEF6
所需的操作
这是结果..