Skip to main content
.NET Framework 4.5.2+

ParametersMode Enum

Contains values specifying how criteria string parameters used in RuleRangeAttribute and RuleValueComparisonAttribute constructors are treated.

Namespace: DevExpress.Persistent.Validation

Assembly: DevExpress.Persistent.Base.v22.1.dll

Declaration

public enum ParametersMode

Members

Name Description
Value

A criteria string is treated as a string.

Expression

A criteria string is treated as an expression. So, you can use the Criteria Language Syntax.

Remarks

The following example demonstrates how to pass this enumeration value to the RuleRange attribute:

using System;
using DevExpress.Persistent.Validation;
//...
private DateTime lastSevenDays;
[RuleRange("LastSevenDays_RuleRange", "Save", "AddDays(LocalDateTimeToday(), -7)", 
    "LocalDateTimeToday()", ParametersMode.Expression)]
public DateTime LastSevenDays {
    get { return lastSevenDays; }
    set { SetPropertyValue(nameof(LastSevenDays), ref lastSevenDays, value); }
}
//...
See Also