private void btnAdd_Click(object sender, EventArgs e) { using (var fm = new EducationForm()) { var result = fm.ShowDialog(); if (result == DialogResult.OK) { vwEducationTableAdapter.Fill(bossDataSet.VwEducation); } } }
private void btnUpdate_Click(object sender, EventArgs e) { var selected = vwEducationBindingSource.Current as DataRowView; var selecteEdu = selected.Row as BossDataSet.VwEducationRow; if (selected == null) { MessageBox.Show("Sətir seçilməyib", "Xəta"); return; } using (var fm = new EducationForm(selecteEdu)) { if (fm.ShowDialog() == DialogResult.OK) { vwEducationTableAdapter.Fill(bossDataSet.VwEducation); } } }