If you are working on complex Flows and need to identify which Flow a certain operation is being performed from –
Example, you are working on some Account Processing Flow you designed for Dataverse tables and there are several Flows for the Account table, but you want to start logging errors from different Flows for developer reference.
Here’s how you can use the workflow() function in Power Automate Flow to get the name of the current Flow –
- Here’s the name of the Flow which we are intending to get in the Flow run itself.
- In this example, I’m initializing a variable of type String to Demonstrate this
- Now, you have workflow() function in the Expressions area in Dynamic Content in your Flow step.
- Once you select the workflow() function, you can continue to type in even though you are not seeing auto-complete options. Type .tags.flowDisplayName further as shown below
- And click OK, make sure by hovering that the expressions is added.
- And when you Run the Flow to test, you can get the Name of the Flow itself.
- Also, you can get the other properties from the workflow() function as well. Here’s an example when you just use workflow() function and see the results –
Hope this was useful!
Here are some Power Automate posts you want to check out –
- Select the item based on a key value using Filter Array in Power Automate
- Select values from an array using Select action in a Power Automate Flow
- Blocking Attachment Extensions in Dynamics 365 CRM
- Upgrade Dataverse for Teams Environment to Dataverse Environment
- Showing Sandbox or Non Production Apps in Power App mobile app
- Create a Power Apps Per User Plan Trial | Dataverse environment
- Install On-Premise Gateway from Power Automate or Power Apps | Power Platform
- Co-presence in Power Automate | Multiple users working on a Flow
- Search Rows (preview) Action in Dataverse connector in a Flow | Power Automate
- Suppress Workflow Header Information while sending back HTTP Response in a Flow | Power Automate
- Call a Flow from Canvas Power App and get back response | Power Platform\
- FetchXML Aggregation in a Flow using CDS (Current Environment) connector | Power Automate
- Parsing Outputs of a List Rows action using Parse JSON in a Flow | Common Data Service (CE) connector
- Asynchronous HTTP Response from a Flow | Power Automate
- Validate JSON Schema for HTTP Request trigger in a Flow and send Response | Power Automate
- Converting JSON to XML and XML to JSON in a Flow | Power Automate