private void btnEdit_Click(object sender, EventArgs e) { FormFichaMesa fichaMesa = new FormFichaMesa(); fichaMesa.Registro = (modelo.mesa)bs.Current; fichaMesa.ShowDialog(); if (fichaMesa.Registro != null) { controle.MesaDB tabela = new controle.MesaDB(); tabela.consultar(bs); bs.ResetBindings(false); } }
private void btnAdd_Click(object sender, EventArgs e) { FormFichaMesa fichaMesa = new FormFichaMesa(); fichaMesa.Registro = null; fichaMesa.ShowDialog(); if (fichaMesa.Registro != null) { controle.MesaDB tabela = new controle.MesaDB(); tabela.consultar(bs); bs.MoveLast(); bs.ResetBindings(false); } }