Skip to main content
.NET Framework 4.6.2+

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

BaseObjectSpace.NonPersistentChangesEnabled Property

Specifies whether the BaseObjectSpace is marked as modified (see BaseObjectSpace.IsModified) when a non-persistent property is changed.

Namespace: DevExpress.ExpressApp

Assembly: DevExpress.ExpressApp.v24.2.dll

NuGet Package: DevExpress.ExpressApp

#Declaration

public bool NonPersistentChangesEnabled { get; set; }

#Property Value

Type Description
Boolean

true, to mark the Object Space as modified when a non-persistent property is changed; otherwise, false. The default is false.

#Remarks

To set this property for all Object Spaces created by the application, handle the OnObjectSpaceCreated event in the Application Builder code:

File: MySolution.Blazor.Server/Startup.cs, MySolution.Win/Startup.cs, MySolution.WebApi/Startup.cs

using DevExpress.ExpressApp;
// ...
builder.ObjectSpaceProviders.Events.OnObjectSpaceCreated = context => {
    BaseObjectSpace os = context.ObjectSpace as BaseObjectSpace;
    if (os != null)
        os.NonPersistentChangesEnabled = true;
};
// ...
See Also