Join the #BuildWithBuildAgent Challenge! Get recognized, earn exclusive swag, and inspire the ServiceNow Community with what you can build using Build Agent.  Join the Challenge.

Workflow is struck after approval is marked cancelled

NagaMounika
Tera Contributor

When ever approval is marked as cancelled or no longer required the approval is getting struck it must move to the next stage any ideas would be helpful

5 REPLIES 5

Brad Bowman
Kilo Patron
Kilo Patron

One approach is to have a parallel activity waiting for the approval cancellation - with both paths leading to the next activity:

BradBowman_0-1763990949625.png

The key to this working is to ensure that a field on the RITM record is updated when the/all approval(s) are cancelled, then the Wait for condition is waiting for this field value.  If you are cancelling approvals via script, you can also update the approval field, such as happens with an Approved or Rejected result, or Stage, or any other field you'd like.  If an admin is cancelling the approvals manually, you would need a Business Rule running on the sysapproval_approver table triggered when the state changes to one of these values, then running a script to look for other active approvals for the same record, updating that record if there aren't any.