//Add to Stock private void toolStripMenuItem1_Click(object sender, EventArgs e) { if (!frmAdd.IsDisposed) { frmAdd.Dispose(); } frmAdd = new AddForm(); frmAdd.InfoAdded += frm_InfoAdded; currentIndex = lstResults.SelectedIndices[0]; frmAdd.ShowForm(items[currentIndex]); }
private void pnlAdd_Click(object sender, EventArgs e) { //InventoryItem itm = new InventoryItem(); if (!frmAdd.IsDisposed) { frmAdd.Dispose(); } frmAdd = new AddForm(); frmAdd.InfoAdded += frm_InfoAdded; frmAdd.ShowForm(); // }