private void supplier_button_Click(object sender, EventArgs e) { if (supp == null) { supp = new SupplierListData(); supp.RefreshDgv += new SupplierListData.DoEvent(ResetSupplier); supp.Show(this); } else { supp.WindowState = FormWindowState.Normal; supp.Focus(); } }
void ResetSupplier() { supp = null; }