private void btnAdd_Click(object sender, EventArgs e) { AddBank addBank = new AddBank(); addBank.ShowDialog(); Refresh(); }
private void btnUpdate_Click(object sender, EventArgs e) { int id = int.Parse(dgBank.SelectedCells[0].FormattedValue.ToString()); var _bank = GloblMain.dbo.Banks.Find(id); AddBank addBank = new AddBank(_bank); addBank.ShowDialog(); Refresh(); }