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.

How to cancel all the running flow from the specific record

ramesh_r
Mega Sage

Hi All,

 

I want to cancel all the running flow from the specific record using a script. 

 

1. I want to get all the running flows from the specific record (dynamicaly)

2. Then I want to cancel all of them using script (Ex : Business rule or script include or background script)

 

 

 

Thanks

 

2 REPLIES 2

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @ramesh_r 

 

Go to this table sys_flow_context

Get the flow name, where state is like this

AGLearnNGrow_0-1710766514971.png

and use it. 

 

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Harish KM
Kilo Patron
Kilo Patron