protected override void OnClosing(CancelEventArgs e) { base.OnClosing(e); e.Cancel = this.closed == -1; if (this.closed == -1) { this.closed = 0; } }