public ActionResult Delete(int id)
        {
            EFDal dal = new EFDal();

            dal.DeleteById(id);
            return(RedirectToAction("DisplayAllEmps"));
        }
Beispiel #2
0
        private void btnDelete_Click(object sender, EventArgs e)
        {
            var Ecode = int.Parse(txtEcode.Text);

            var dal = new EFDal();

            dal.DeleteById(Ecode);
            MessageBox.Show("record deleted");
            dgv.DataSource = dal.GetAllEmps();
        }
Beispiel #3
0
        public void DeleteEmp(int ecode)
        {
            EFDal dal = new EFDal();

            dal.DeleteById(ecode);
        }