Id: | 14170 |
Product: | finPOWER Connect |
Type: | NEW |
Version: | 3.00.03 |
Opened: | 18/05/2016 |
Closed: | 18/05/2016 |
Released: | 01/12/2016 |
Job: | J017398 |
Account Type Rules; new Script event fires for each Rule before being actioned
A new Account Type Script event fires for each Rule before being actioned. This allows you to add additional tests and run custom Actions.
To configure the script create a new "Object Events" type script, object "Account". Paste Template code and modify the "OverdueRule" event. Then link this script under each Account Type, Scripts page, "OverdueRule" script.
Note, this event only fires after the Account Type Rule's tests have been successfully passed.
If you do not want the Rule to run, i.e. the script includes additional tests, Return False. Sample code is shown below:
Main = False
finBL.Error.ErrorBeginFormat("Overdue Rule '{0}' failed to meet scripted conditions", AccountTypeRule.RuleId)
If you have custom Actions you wish to run then you should do this here, and make sure you return True. Set eventHandled to True if you do not want to run normal Rule Actions.
Note, the Rule's "Halt Rule processing?" setting will determine whether or not additional Rules are run.