How to create a dialog window or something similar to confirm a delete action before deleting a datagrid row?
In WPF there are "preview" events that get called before the "standard" event gets called. These events have the word Preview prefixed on the event name (i.e. PreviewMouseDown). In the "preview" event you can display a MessageBox, or something similar, asking the user to confirm the deletion. If the user confirms the deletion let the event continue. Otherwise you can mark the event as handled and the "standard" event will not execute.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With