You are looking for:
db.Users.Attach(updatedUser);
var entry = db.Entry(updatedUser);
entry.Property(e => e.Email).IsModified = true;
// other changed properties
db.SaveChanges();
More Related Contents:
- Non-static method requires a target
- Returning a file to View/Download in ASP.NET MVC
- ASP.NET MVC: Custom Validation by DataAnnotation
- Entity Framework (EF) Code First Cascade Delete for One-to-Zero-or-One relationship
- Why is JsonRequestBehavior needed?
- How do I enable HTTP PUT and DELETE for ASP.NET MVC in IIS?
- MVC3 Razor DropDownListFor Enums
- Redirect From Action Filter Attribute
- Get return value from stored procedure
- How to get current user timezone in c#
- Why Interface Layer/Abstract classes required in our project? [closed]
- How to render a Razor View to a string in ASP.NET MVC 3?
- Generic method multiple (OR) type constraint
- How do I define a method in Razor?
- Get number of listeners, clients connected to SignalR hub
- Mapping Database Views to EF 5.0 Code First w/Migrations
- Do asynchronous operations in ASP.NET MVC use a thread from ThreadPool on .NET 4
- EF migration for changing data type of columns
- How do you clear cookies using asp.net mvc 3 and c#?
- MaxLength Attribute not generating client-side validation attributes
- How do I use Web.Config transform on my connection strings?
- How to retain spaces in DropDownList – ASP.net MVC Razor views
- Redirect to another page when user is not authorized in asp.net mvc3
- How to manually load related entities in a N:N relationship?
- Uploading image in ASP.NET MVC
- The ObjectContext instance has been disposed and can no longer be used for operations that require a connection [duplicate]
- System.Data.MetadataException: Unable to load the specified metadata resource
- Output cache per User
- Modelling polymorphic associations database-first vs code-first
- MVC Form Validation on Multiple Fields