private void btnAdd_Click(object sender, EventArgs e) { frmAddWarehouse frm = frmAddWarehouse.GetInstance(); frm.Closing += Frm_Closing; frm.ShowDialog(); }
public static frmAddWarehouse GetInstance() { if (_instance == null) { _instance = new frmAddWarehouse(); } return(_instance); }
private void dgWarehouse_CellClick(object sender, DataGridViewCellEventArgs e) { if (e.ColumnIndex == 4) { frmAddWarehouse frm = new frmAddWarehouse(dgWarehouse.CurrentRow.Cells[0].Value.ToString()); frm.Closing += Frm_Closing; frm.ShowDialog(); } }
private void dgWarehouse_CellClick(object sender, DataGridViewCellEventArgs e) { if (e.ColumnIndex == 4 ) { frmAddWarehouse frm = new frmAddWarehouse(dgWarehouse.CurrentRow.Cells[0].Value.ToString()); frm.Closing += Frm_Closing; frm.ShowDialog(); } }