Terminate a Flow with Failed/Cancelled status | Power Automate

Usually, things don’t fall into a certain condition and we tend to leave the Flow like that.

Use Terminate control in a Flow in Power Automate to correctly end a Flow Run by declaring that it wasn’t successful.

Scenario

At times, when we use Condition i.e. If True or False, we put everything in True and nothing in False, just keeping it blank.

And when the condition turns out that it doesn’t match the True part, it’ll go in False part and end the Flow. The status will still say Success because the Flow ran completely without any issues.

And when you try to search that Flow Run amongst all the results, you’re not quite sure because they show all Succeeded. This is where you can use Terminate Control to identify what didn’t go according to the condition so that you can identify that the Flow didn’t complete it’s intended purpose.

Terminate Control

You can use Terminate control to stop a Flow execution and result in a different message other than Success so that you ease the identification of which Flow Run went wrong just by looking at the Flow Runs results.

You can chose between Different types of termination Actions

You can choose between Failed or Cancelled.

Failed

If you selected Failed, you’ll be able to post a custom error code and a message

Cancelled
And when you select Cancelled, you don’t need to do much.

Working

So when the If condition is not True, if will go in False like shown below –

And if you open the same, it’ll show that it wasn’t successful.

If the Status was chosen as Cancelled, Cancelled will appear

And inside the Flow, it’ll appear like this

That way, you can pick the Failed Run and investigate the Flow based on the way you chose to terminate the Flow.

Here are some more Flow / Power Automate posts you might want to check out –

  1. ChildFlowUnsupportedForInvokerConnections error while using Child Flows [SOLVED] | Power Automate
  2. BPF Flow Step as a Trigger in CDS (Current Environment) connector | Power Automate
  3. Pause a Flow using Delay and Delay Until | Power Automate
  4. Generate Dynamics 365 record link in a Flow using CDS connector | Power Automate
  5. Text Functions in a Flow | Power Automate
  6. Get Count of records retrieved in CDS connector in a Flow | Power Automate
  7. Loop through array of objects in a Flow & Create records in CDS | Power Automate
  8. Make HTTP request from Flow in Power Automate
  9. Enable Flow button on D365 Ribbon
  10. Number Formatting in a Flow | Power Automate

Hope this helps!

Advertisement

ChildFlowUnsupportedForInvokerConnections error while using Child Flows [SOLVED] | Power Automate

Often times, if you are using Child Flows and but you see some unexpected while Saving your parent Flows upon adding a Child Flow, which usually look like the below
undefined

Assuming, you are aware of using Child Flows and that they can only be created inside a Solution. (Of course, that’s why you could encounter this issue since you’re able to set a Child Flow already 😊)

Reason Issue

Let’s say this is your Child Flow as shown below in Power Automate. It uses a connection for Approvals. (It could be any other connection in your case.)
undefined

Now, open Run only users section as shown below
undefined

It’ll show that my Approvals connection is relying on Provided by run-only user in Power Automate. To learn more about Run only Users, refer this post – https://www.serverlessnotes.com/docs/sharing-flows-as-owners-and-run-only-users

Now, I switch to Use this connection (<Connector>)
undefined

It’ll ask for a confirmation as per below
undefined

Once this is set for all respective connections, you’ll have no issues in adding a Child Flow to your parent Flow and saving your parent Flow!

Here are some more Power Automate / Flow posts you might want to look at –

  1. BPF Flow Step as a Trigger in CDS (Current Environment) connector | Power Automate
  2. Pause a Flow using Delay and Delay Until | Power Automate
  3. Generate Dynamics 365 record link in a Flow using CDS connector | Power Automate
  4. Get Count of records retrieved in CDS connector in a Flow | Power Automate
  5. Loop through array of objects in a Flow & Create records in CDS | Power Automate
  6. Call a Dynamics 365 Action from Flow [Bound and Unbound Actions] | Power Automate
  7. Number Formatting in a Flow | Power Automate
  8. Text Functions in a Flow | Power Automate
  9. Setting Retry Policy for an HTTP request in a Flow | Power Automate
  10. Make HTTP request from Flow in Power Automate

Hope this quick tip helps!