void ProcessForm(Exception Ex, bool Continue = true) { ExceptionForm ExForm = new ExceptionForm(Ex, Continue); try { DialogResult Result = ExForm.ShowDialog(); switch (Result) { case DialogResult.OK: break; case DialogResult.Cancel: Environment.Exit(0); break; } } finally { ExForm.Dispose(); } }