Top Method Summary
Options Name Purpose
ApplyResult (logical) Stores the result of the rule evaluation and updates the error marker of the field
ControlLeaveHandler (Object, EventArgs) Event handler for the Leave event of the field
HandleEvaluationError (Error) Handles an error raised while evaluating the rule
Reset () Resets the rule to its initial state (satisfied, field not visited yet)
Validate () Evaluates the rule as if the user had left the field

Top Constructor Summary
Options Name Purpose
ViewerFieldValidationRule (Control, character, SmartViewerControl, integer, character) Constructor of the ViewerFieldValidationRule class

Top Property Summary
Options Name Purpose
System.Windows.Forms.Control Control
INTEGER RuleNumber
LOGICAL Satisfied
CHARACTER ValidationMessage


Method Detail
Top

ApplyResult (logical)

Purpose: Stores the result of the rule evaluation and updates the error
marker of the field
Notes:

Parameters:
plResult LOGICAL
The result of the rule expression
Top

ControlLeaveHandler (Object, EventArgs)

Purpose: Event handler for the Leave event of the field
Notes: From now on the result of the rule is shown at the field

Parameters:
sender System.Object
The reference to the sender of the event
e System.EventArgs
The System.EventArgs with the data for this event
Top

HandleEvaluationError (Error)

Purpose: Handles an error raised while evaluating the rule
Notes: The error depends on the value of the field (e.g. ENTRY beyond
the end of a list) and counts as a failed rule - the same
semantics as for an EnableRule or VisibilityRule (SCL-6249),
but every failure is logged

Parameters:
poError Progress.Lang.Error
The reference to the error raised by the evaluation
Top

Reset ()

Purpose: Resets the rule to its initial state (satisfied, field not
visited yet)
Notes:

Top

Validate ()

Purpose: Evaluates the rule as if the user had left the field
Notes: Called by the viewer before saving



Constructor Detail
Top

ViewerFieldValidationRule (Control, character, SmartViewerControl, integer, character)

Purpose: Constructor of the ViewerFieldValidationRule class
Notes:

Parameters:
poControl System.Windows.Forms.Control
The reference to the field (editor control) to validate
pcRule CHARACTER
The ValidationRules expression from the repository attributes of the field
poViewer Consultingwerk.SmartComponents.Base.SmartViewerControl
The reference to the viewer containing the field, used to resolve the rule tokens and to mark the field
piRuleNumber INTEGER
The number of the rule (1 to 5)
pcValidationMessage CHARACTER
The (translated) message shown when the rule is not satisfied


Property Detail
Top

System.Windows.Forms.Control Control


Returns System.Windows.Forms.Control
Top

INTEGER RuleNumber


Returns INTEGER
Top

LOGICAL Satisfied


Returns LOGICAL
Top

CHARACTER ValidationMessage


Returns CHARACTER


©2006-2026 Consultingwerk Ltd.         info@consultingwerk.de         http://www.consultingwerk.de       09.11.2026 08:19:38