How to return data in custom state after one or more of the workflow actions conditions met?

So I have this app that requires me to check every input with certain conditions. Whenever the user clicks the submit button, the first step is to trigger the custom event, which checks these inputs by triggering a “show alert” when the conditions are met.

What I want to do is if the actions in the custom event didn’t trigger, then return yes and if one of the actions was triggered, then return no.

with this returned data, I can terminate the main workflow if it returns no.

And I’m struggling with how to set up the conditions to return data
.

1 Like

Still no reply…

I figured this out by doing this:
So whenever you set a condition for your inputs in the show alert action in your custom workflow, you add a return data action with the same condition as the previous show alert action, and the returned data should be yes or no.

For example, my return data type is yes or no and called “success?” because I am validating an input if the conditions are met that means unsuccessful so I return the data as “no”, and if every input was valid, then I create a unconditional return data action with the value yes.

Since I can’t find this information anywhere then let me write it here:
When using return data, the custom workflow will automatically stop.

And finally, what do I do with the returned data? I simply just create a terminate workflow action after the custom event in the main workflow, which has a condition that this action only runs when the returned value is no.

This topic was automatically closed after 70 days. New replies are no longer allowed.