Ejemplo n.º 1
0
 /// <summary>
 /// This function will update the entries in the SQL table to the inserted vales
 /// </summary>
 /// <param name="std">Student object with updated values</param>
 public void UpdateDL(Student std)
 {
     using (TestDBEntities context = new TestDBEntities())
     {
         context.Entry(std).State = System.Data.Entity.EntityState.Modified;
         context.SaveChanges();
     }
 }
Ejemplo n.º 2
0
 /// <summary>
 /// This function will update the entries in the SQL table to the inserted values
 /// </summary>
 /// <param name="emp">Object with updated values of the column in Employee object</param>
 public void UpdateDL(Employee emp)
 {
     using (TestDBEntities context = new TestDBEntities())
     {
         context.Entry(emp).State = System.Data.Entity.EntityState.Modified;
         context.SaveChanges();
     }
 }