Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post May 26, 2012 10:53 AM by CPrakash82
May 26, 2012 09:45 AM|LINK
I have the following code that works fine if I pass all the values of a “Page” back from my view. My problem is that in this view I only have two of the database fields that I want to update.
This code updates the two fields from my view fine but sets the rest back to NULL. What is the best way to get around this?
public ActionResult Page(Page page)
May 26, 2012 10:53 AM|LINK
can you try something like this.
var entry = db.ObjectStateManager.GetObjectStateEntry(page);