Re: Is it possible to catch validation errors after session.Fire() call?

62 views
Skip to first unread message
Message has been deleted
Message has been deleted

NRules

unread,
Apr 17, 2019, 12:39:41 PM4/17/19
to NRules Users
Is it possible to catch validation errors after session.Fire() call if we use this as an example: https://github.com/NRules/NRules/wiki/Getting-Started#running-rules?
Should there be some timeout after session.Fire() so that everything gets validated?

Sergiy Nikolayev

unread,
Apr 23, 2019, 7:52:40 PM4/23/19
to NRules Users
I don't quite understand what you mean by "validation errors". Session.Fire does not return until all rules have finished running, so if you were doing some validation in the rules, they will all have run by the time the method returns. For some more details on handling validation with NRules, you can also check out this SO question: https://stackoverflow.com/questions/32554222/how-to-create-a-validation-rule-with-nrules
Reply all
Reply to author
Forward
0 new messages