Where Did Detach() Go In Entity Framework



TODO:

You are migrating old code to the latest version of Entity Framework, and you no longer have the Detach() method.  To fix, use the code below.

 

SOLUTION:

((IObjectContextAdapter)myModel).ObjectContext.Detach(myobject);

 

NOTES:

There are no notes on this topic.



Add comment

  Country flag

biuquote
  • Comment
  • Preview
Loading