public void remoeddata()
 {
     try
     {
         int idsds = int.Parse(operationis.Text);
         hy = gt.OperationRequsts.Where(p => p.operationID == idsds).First();
         gt.OperationRequsts.Remove(hy);
         gt.SaveChanges();
         clear();
     }
     catch (Exception wer)
     {
         MessageBox.Show(wer.Message.ToString());
     }
 }
 public void updatss()
 {
     try
     {
         int idsds = int.Parse(operationis.Text);
         hy                   = gt.OperationRequsts.Where(p => p.operationID == idsds).First();
         hy.PatientID         = int.Parse(paitentid.Text);
         hy.PatientName       = name.Text;
         hy.FatherName        = fathername.Text;
         hy.Sex               = sex.Text;
         hy.Age               = int.Parse(Age.Text);
         hy.Date              = dates.Text;
         hy.PhysicianName     = physicianname.Text;
         hy.OperatienDate     = operationdate.Text;
         hy.AssignedPhysician = assignphysician.Text;
         hy.Specification     = specification.Text;
         gt.SaveChanges();
         clear();
     }
     catch (Exception v3)
     {
         MessageBox.Show(v3.Message.ToString());
     }
 }
 public void savedata()
 {
     try
     {
         hy                   = gt.OperationRequsts.Create();
         hy.PatientID         = int.Parse(paitentid.Text);
         hy.PatientName       = name.Text;
         hy.FatherName        = fathername.Text;
         hy.Sex               = sex.Text;
         hy.Age               = int.Parse(Age.Text);
         hy.Date              = dates.Text;
         hy.PhysicianName     = physicianname.Text;
         hy.OperatienDate     = operationdate.Text;
         hy.AssignedPhysician = assignphysician.Text;
         hy.Specification     = specification.Text;
         gt.OperationRequsts.Add(hy);
         gt.SaveChanges();
         clear();
     }
     catch (Exception se)
     {
         MessageBox.Show(se.Message.ToString());
     }
 }