private void positionEditButton_Click(object sender, EventArgs e) { if (PositionsListBox.SelectedItems.Count == 1) { int position_id = int.Parse(PositionsListBox.SelectedValue.ToString()); AddEditPosition AddEditPosition = new AddEditPosition(position_id); AddEditPosition.Show(); } else { MessageBox.Show("Select a position"); } }
private void positionAddButton_Click(object sender, EventArgs e) { AddEditPosition AddEditPosition = new AddEditPosition(0); AddEditPosition.Show(); }