title: WinForms data binding with a Save button?
body: <p><strong>How is data binding in C# WinForms supposed to work when you have a Save button?</strong> I don't want the data updated until I press Save!</p>
  
  <p>I have two forms (list and detail) backed by a <code>BindingList&lt;T&gt;</code> collection and my custom object from that collection, respectively. I can bind each form to the list or object appropriately. However, any changes made in the detail form are immediately reflected in the list form - I don't want to save the changes and update the details shown in the list until the Save button is pressed.</p>
  
  <p>Is data binding designed to support this? Is there a common pattern for doing so?</p>
  
  <p>Whichever way I look at it, binding doesn't seem to be able to support this scenario. I've considered the following:</p>
  
  <ul>
  <li><p>Pass a clone of the object to the detail form, but then I have to reconcile the changes on Save - changes may have been made to the copy in the list in the meantime.</p></li>
  <li><p>Implementing <code>IEditableObject</code> and calling <code>EndEdit</code> on save almost works as I can prevent the list being notified of the changes made until Save is pressed, but if something else causes a refresh the list is updated with the interim data.</p></li>
  </ul>
  
  <p>I'm currently left with dispensing with data binding in my detail view, and doing it all manually. Which is rather annoying.</p>