Пример #1
0
        public void UpdateRecord(tblPatient obj)
        {
            db.tblPatients.Attach(obj);
            var update = db.Entry(obj);

            update.Property(x => x.Age).IsModified             = true;
            update.Property(x => x.Contact_no).IsModified      = true;
            update.Property(x => x.Gender).IsModified          = true;
            update.Property(x => x.Note).IsModified            = true;
            update.Property(x => x.Patient_address).IsModified = true;


            update.Property(x => x.Patient_Name).IsModified = true;
            db.SaveChanges();
        }