Option to ask for confirmation to call SubmitChanges();
I have a lot of queries I use day to day. I have recently started using SubmitChanges to update data when needed. I have this line commented out by default but worry that sometimes I could forget. Would be nice to have an option to that when enabled asks for confirmation to perform SubmitChanges()
Simon Lawrence commented
Sure, works when you add the namespace for "System.Windows.Forms". But not quite as convenient as a tickbox in the options. But thanks for the code.
Dave Shaw commented
You could create your own like this:
if (MessageBox.Show("Save?", "Save?", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)