title: Entity Framework Saving new Objects Returns a Populated ID?
body: <p>Please help me understand this.</p>
  
  <p>When I save a new object to the database (using Entity Framework), am I able to access the newly created ID (Identity column) value in the line(s) after I call db.SaveChanges()? </p>
  
  <pre><code>public Class TheObject
  {
      public int ID { get; set; }
      public string FirstName { get; set; }
  }
  
  .....
  
  TheObject MyObject = new TheObject();
  MyObject.FirstName = "John";
  
  db.TheObjects.Add(MyObject);
  db.SaveChanges();
  
  int MyNewID = MyObject.ID; //Am I able to access MyObject.ID here and have access to the value that was just created in the database?
  </code></pre>