private void bt_AddGroup_Click(object sender, EventArgs e) { if (comboBox1.Items.IndexOf(comboBox1.Text) == -1) { string NewGroup = comboBox1.Text; GroupActivitiesOperations.AddGroup(comboBox1.Text, EmpID[comboBox3.SelectedIndex]); GroupActivitiesOperations.FillGroupForm(this); comboBox1.SelectedItem = NewGroup; } else { MessageBox.Show("Группа с таким названием уже создана"); } }
private void FormGroup_Load(object sender, EventArgs e) { GroupActivitiesOperations.FillGroupForm(this); }