title: EF 4: Problems understanding DetectChanges when using POCO (no self tracking ObjectContext)
body: <p>I wonder if anyone can help me?</p>
  
  <p>I am having problems understanding why i need to issues DetectChanges on my POCO (non proxy) entities.</p>
  
  <p>Of course i have this line to ensure that proxies are not returned.</p>
  
  <pre><code>   context.ObjectStateManager.GetObjectStateEntry(order).State
  </code></pre>
  
  <p>And doing some research it appears if i need to check the "state" of an object then i need to issue detechChanges But why would i need to check the State of an object?</p>
  
  <p>Basically I send along my POCO entity to a method that SAVES the data to a new ObjectContext (I create and destroy ObjectContext on each method)</p>
  
  <p>Hence, i am having problems understanding why i would need to have ObjectContext track or be aware of changes?</p>
  
  <p>Is it because that if its not aware if will not be saved?</p>
  
  <p>Maybe i am miss informed but it appears that if i am using an existing ObjectContext (which i am not i am creating and destroying each time) that ensure ObjectContext is aware would be beneficial but otherwise not?</p>
  
  <p>So in 1 method I am updating an object by creating a new datacontext, saving it to the db and destroying ObjectContext . Hence i am not using 2 methods, 1 method to send the update or new record and then another method for SAVING.</p>
  
  <p>I would really appreciate any quick explaanations of why its needed?</p>
  
  <p>Thanks in advance</p>