How can I prevent window closing by showing a MessageBox? (Technology:WinForms with C#)
MessageBox
WinForms
C#
When the close event occurs I want the
Within your OnFormClosing event you can show the dialog and if answer is false (to not show) then set the Cancel property of the EventArgs to true.
OnFormClosing
if
Cancel
EventArgs
true