Skip to main content
A newer version of this page is available. .
.NET Framework 4.5.2+

ImmediatePostDataAttribute Class

Applied to business class properties. Indicates that the property editor’s control value should be passed to the property of a bound object as soon as possible when the value is changed by user. For instance, it allows you to enforce updating other displayed values that are calculated based on the current property.

Namespace: DevExpress.Persistent.Base

Assembly: DevExpress.ExpressApp.v19.2.dll

Declaration

[AttributeUsage(AttributeTargets.Property, Inherited = true, AllowMultiple = false)]
public sealed class ImmediatePostDataAttribute :
    ModelExportedValueAttribute

Remarks

The code snippet below demonstrates how to apply the ImmediatePostData attribute to a business class property in code.

using DevExpress.Persistent.Base;
// ...
[ImmediatePostData]
public double Rate {
    get {
        //...
    }
    set {
        //...           
    }
}

In ASP.NET applications, changing the property value will cause an immediate refresh at the loss of input focus. In Windows Forms and Mobile applications, the current property’s value will update immediately.

By applying the attribute, you automatically set the Application Model‘s BOModel | <Class> | OwnMembers | <Member> | ImmediatePostData default property value to true.

ImmediatePostData_ApplicationModel_BOModel

Note that you can set or change this property’s value using the Model Editor as shown in the Make a Property Calculable topic.

Any changes to the BOModel | <Class> | OwnMembers | <Member> | ImmediatePostData property value affect the default value of the same property in the following nodes:

  • Views | <DetailView> | Items | <PropertyEditor>,
  • Views | <ListView> | Columns | <Column>.

You can modify the property’s value in the nodes above to, for example, disable ImmediatePostData for certain Views.

ImmediatePostData_ApplicationModel_Views

These nodes’ ImmediatePostData properties specify the default values for the corresponding PropertyEditor.ImmediatePostData properties.

The diagram below demonstrates different levels where the ImmediatePostData setting can be applied. Higher levels determine default values for lower levels.

ImmediatePostData_Class

Note

  • This functionality has certain limitations in an editable List View in ASP.NET applications. Ensure that the application behavior meets your requirements before publishing your application. You can always invoke the Model Editor for the ASP.NET project and disable the Views | <ListView> | Columns | <Column> | ImmediatePostData property for a specific column.
  • In Mobile applications, non-persistent calculated reference properties are not updated.

Inheritance

Object
Attribute
DevExpress.Persistent.Base.ModelExportedValueAttribute
ImmediatePostDataAttribute
See Also