MoneyWorks Manual
ValidateField (windowRef, fieldNameString, fieldValueString)
A script handler you can implement to override standard MoneyWorks behaviour.
Automatically called: When a field is about to be exitted. Return 0 if the field value is not acceptable: this will keep the focus in the field. IMPORTANT: If you do this you should provide an explanation to the user via an alert or coachtip. Users will be very unhappy if they don't know why they can't exit a field!
Return value: Boolean
Use for: Validating the contents of a field. You can also call CheckCodeField to present a code choices dialog box if the field is not a valid code for a particular table.
Specific Naming: You can and should implement an ValidateField handler that is specific to the particular window ID and itemID of interest. e.g. ValidateField:<WindowId>:ItemID:<TransactionType> (the last of these applies only when the WindowID is F_TRANS)