Ejemplo n.º 1
0
 private void btnAdd_Click(object sender, EventArgs e)
 {
     using (frmAddEditReader frm = new frmAddEditReader(null))
     {
         if (frm.ShowDialog() == DialogResult.OK)
         {
             readerBindingSource.DataSource = _controller.GetAll();
         }
     }
 }
Ejemplo n.º 2
0
        private void btnEdit_Click(object sender, EventArgs e)
        {
            if (readerBindingSource.Current == null)
            {
                return;
            }

            using (frmAddEditReader frm = new frmAddEditReader(readerBindingSource.Current as Reader))
            {
                if (frm.ShowDialog() == DialogResult.OK)
                {
                    readerBindingSource.DataSource = _controller.GetAll();
                }
            }
        }