private void btn_edit_Click(object sender, EventArgs e) { int realIndexItem = int.Parse(lsv_items.Items[lsv_items.SelectedIndices[0]].Text); Item item = m_databaseItems[realIndexItem]; CreateItem frmItem = new CreateItem(m_databaseTemplates, m_databaseItems, item); frmItem.itemManager = this; frmItem.ShowDialog(); if (wasAnEdit) { LoadItems(); } btn_edit.Enabled = false; btn_delete.Enabled = false; btn_edit.Enabled = false; btn_delete.Enabled = false; }
private void mnu_create_item_Click(object sender, EventArgs e) { CreateItem frmItem = new CreateItem(m_lstTemplates, m_lstItems); frmItem.ShowDialog(); }