private void Button_Click(object sender, EventArgs e) { ButtonWithTicket button = sender as ButtonWithTicket; if (_formTests == null) { _formTests = new FormTests(button.Ticket); _formTests.FormClosed += FormTests_FormClosed; _formTests.Show(this); } else { } }
private void FormTests_FormClosed(object sender, FormClosedEventArgs e) { _formTests = null; }