//Creating Employee DataContext object
EmployeeDBDataContext db = new EmployeeDBDataContext();
//Selecting an employee to update his name and address
emp = db.Employees.Single(e => e.EmpID == 1);
emp.Name = "Sabu";
emp.Address = "Cochin";
//Submitting changes
db.SubmitChanges();
Nice one!!!!!! i was searching long back
ReplyDelete