private void buttonUpdate_Click(object sender, EventArgs e) { if (Selected_Table != "") { if (Validate()) { UpdateRecord?.Invoke(Selected_Table, SelectedItemIndex); } else { MessageBox.Show("Values can't be null!"); } } }
private void button1_Click(object sender, EventArgs e) { UpdateRecord.Invoke(this, new People(firstNameTextBox.Text, lastNameTextBox.Text)); }