QuickObjects.ObjectBase Send comments on this topic.
RangeFieldValidator Class Members
See Also  Fields  Properties  Methods 
Akal.QuickObjects.ObjectBase Namespace : RangeFieldValidator Class


The following tables list the members exposed by RangeFieldValidator.

Public Constructors

 NameDescription
Public ConstructorRangeFieldValidator ConstructorOverloaded. Default Constructor - provides no special functionality.  
Top

Protected Fields

 NameDescription
Protected Field_errorString (Inherited from BaseFieldValidator)
Top

Public Properties

 NameDescription
Public PropertyCustomErrorMessageOverridden.  CustomErrorMessage can be used to specify the error message that will be formatted and returned instead of the standard error message.

NOTE: Formatting can be specified by using {0} and {1} place holders inside the string.

The following place holders can be used:

  • {0} will be replaced with the field's name or alias [GetResultSetName() method]

  • {1} will be replaced with the business object's name or alias [GetResultSetName() method].

  • {2} will be replaced with the actual value of the field.

  • {3} will be replaced with minimum value.

  • {4} will be replaced with maximum value.

  • {5} will be replaced with MinimumValueField's name or alias.

  • {6} will be replaced with MaximumValueField's name or alias.

 
Public PropertyEnabled Enabled property can be used to easily turn off or on a validator. If the value of Enabled is set to false, this validator will not be used in validation. (Inherited from BaseFieldValidator)
Public PropertyErrorStringOverridden. If the validation fails the error message is available via this property.

If the CustomErrorMessage is set, the ErrorString property will automatically return the CustomErrorMessage after formatting it.

 
Public PropertyFieldToValidateField instance that will be validated by this validation. (Inherited from BaseFieldValidator)
Public PropertyIsNullValid IsNullValid determines if a Field is null then this validator will consider the field value to be valid or not.  
Public PropertyIsValid Returns true if the validation is valid or the FieldToValidate property is null. (Inherited from BaseFieldValidator)
Public PropertyMaximumValue

MaximumValue will hold the lowest possible value in the range of valid values for the field.

Note: If the MaximumValueField property is specified that will be used instead of MaximumValue property. MaximumValue property is only used if the MaximumValueField is null.

Values of following types are acceptable:

  • Byte
  • UInt16
  • UInt32
  • UInt64
  • Int16
  • Int32
  • Int64
  • Single
  • Double
  • Decimal
  • DateTime
 
Public PropertyMaximumValueField MaximumValueField can be used to specify another Field object where the MaximumValue for this validation should be retreived from.

Note: If the MaximumValueField property is specified that will be used instead of MaximumValue property. MaximumValue property is only used if the MaximumValueField is null.

 
Public PropertyMinimumValue

MinimumValue will hold the lowest possible value in the range of valid values for the field.

Note: If the MinimumValueField property is specified that will be used instead of MinimumValue property. MinimumValue property is only used if the MinimumValueField is null.

Values of following types are acceptable:

  • Byte
  • UInt16
  • UInt32
  • UInt64
  • Int16
  • Int32
  • Int64
  • Single
  • Double
  • Decimal
  • DateTime
 
Public PropertyMinimumValueField MinimumValueField can be used to specify another Field object where the MinimumValue for this validation should be retreived from.

Note: If the MinimumValueField property is specified that will be used instead of MinimumValue property. MinimumValue property is only used if the MinimumValueField is null.

 
Public PropertyName Used to uniquely identify each validator. When a new Field instance is passed into the constructor or the FieldToValidate property is set, the Name property is automatically populated, hence it is not required to set this value. Setting this value to a custom name will help you access this validator instance from the Validators collection by using the custom name. (Inherited from BaseFieldValidator)
Public PropertyValidatorTypeOverridden.  ValidatorType - Returns the value ValidatorTypes.RangeFieldValidator.  
Top

Public Methods

 NameDescription
Public MethodGetValidatorTypeNameOverridden.  GetValidatorTypeName - Returns string value for the validator type.  
Public MethodValidateOverridden.  Returns false if the validator fails. If the FieldToValidate is null then then this method returns true.  
Top

See Also