Advertisement
Guest User

Untitled

a guest
Jul 23rd, 2014
203
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  1. public class MyTable
  2. {
  3. public int Id { get; set; }
  4. public Nullable<int> MyInt { get; set; }
  5. }
  6.  
  7.  
  8. void UpdateRow(MyTable currentRow)
  9. {
  10. MyTable rowToUpdate = transaction.entity.Find(currentRow.Id);
  11.  
  12. rowToUpdate.MyInt = currentRow.MyInt;
  13.  
  14. transaction.Context.SaveChanges();
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement