Is there any functionality in flow to run custom script as Run script activity in workflow ?

1_DipikaD
Kilo Sage

Hi All,

 

Is there any functionality in flow to run custom script as Run script activity in workflow ? When condition matches I want to trigger a script in flow designer. 

 

Thank You

1 ACCEPTED SOLUTION

@1_DipikaD 

you can add 2 script steps in same custom action or have 2 custom actions with 1 script step in each of those

it's as per your customer requirement.

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

23 REPLIES 23

Hi @Ankur Bawiskar ,

Is this ok to only mention script without mentioning input and output variable . I want to run 2 scripts one after another so I need to create 2 custom actions like this or I can reuse this ? Please guide me on this .

 

 

 

@1_DipikaD 

you can add 2 script steps in same custom action or have 2 custom actions with 1 script step in each of those

it's as per your customer requirement.

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Facing the below error while testing the flow . Could you please help me to know why it's coming. Am I missing anything ?

 

 

@1_DipikaD 

some error in your custom action.

open the action context and see that script

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Can we not use current.variables object in flow designer ? I have tried the below script it's throughing the Error: Cannot read property "variables" from null,Detail: Cannot read property "variables" from null .