SaveOptions SaveOptions SaveOptions SaveOptions Enum


Specifies the behavior of the object context when the SaveChanges(SaveOptions) method is called.

This enumeration has a FlagsAttribute attribute that allows a bitwise combination of its member values.

public enum class SaveOptions
public enum SaveOptions
type SaveOptions = 
Public Enum SaveOptions


AcceptAllChangesAfterSave AcceptAllChangesAfterSave AcceptAllChangesAfterSave AcceptAllChangesAfterSave 1

After changes are saved, the AcceptAllChangesAfterSave method is called, which resets change tracking in the ObjectStateManager.

DetectChangesBeforeSave DetectChangesBeforeSave DetectChangesBeforeSave DetectChangesBeforeSave 2

Before changes are saved, the DetectChanges() method is called to synchronize the property values of objects that are attached to the object context with data in the ObjectStateManager.

None None None None 0

Changes are saved without the DetectChanges() or the AcceptAllChangesAfterSave methods being called.

Applies to