private void newItem_Click(object sender, System.EventArgs e) { AddComboItemForm dlg = new AddComboItemForm(); DialogResult result = dlg.ShowDialog(this); if (result == DialogResult.OK) { string newItem = dlg.NewItem; combo.Items.Add(newItem); } }
private void newItem_Click(object sender, System.EventArgs e) { AddComboItemForm dlg = new AddComboItemForm(); DialogResult result = dlg.ShowDialog(this); if(result == DialogResult.OK) { string newItem = dlg.NewItem; combo.Items.Add(newItem); } }