FormClosing

  • Thread starter Thread starter dani kotlar
  • Start date Start date
D

dani kotlar

Is it possible to suspend the closing of a form from the FormClosing
event handler, or any other way?
Thanks
 
If by suspend, you mean cancel the closing, then yes.

protected override void OnClosing(CancelEventArgs e)
{
if(someCondition)
e.Cancel = true;
}
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top