Build a cloud flow that's triggered in Outlook
Now that you have a desktop flow, you're ready to create a solution in Power Automate. Solutions are groups of apps and flows that are packaged together and enable seamless application lifecycle management (ALM). For example, when you host your flow in a solution, both become portable, making it effortless to move them and all their components from one environment to another, in other words, from development to production. Flows that are built inside solutions are called solution-aware flows. You can't move a non solution-aware flow into a solution, so if you think that you need a solution, create your flow from the solution from the beginning to avoid needing to rebuild your flow.
Watch the following demo video of the steps that you complete in this unit.
Create a solution
Go to Power Automate to get started, select Solutions on the left navigation menu, and then select New solution.
Set the display name for your solution. In this case, the display name is Invoice processing solution, but you can make it whatever you want.
Note
Notice the Name field fills in automatically as you typed the Display Name field. Solutions are built on Microsoft Dataverse, and the Name field can't use spaces. This allows for easier calling inside of other apps and solution-aware flows.
Set the publisher as CDS Default Publisher and then select Create.
This screen is where you create and edit flows that are specific to this solution.
Create cloud flow in solution
To create a new solution-aware flow, select + New > Automation > Cloud flow > Automated.
Name the flow, Use Outlook email trigger Desktop flow, or you can choose whatever name you want.
Search in the Choose your flow's trigger field to find and select When a new email arrives (V3) and then select Create.
Note
Always use the latest version of the action that you're seeking, which will ensure that you have access to new features that have been released.
The flow opens in the New Designer. Select the trigger and the properties panel opens from the left hand side.
Select Show All next to the advanced parameters to display all parameters.
Ensure that Include Attachments and Only with Attachments fields have Yes selected.
In the Subject Filter field, enter new invoice.
Set up Run a flow built with Power Automate for Desktop Action
Select the + icon underneath the trigger and then Add an action.
Search for and select the Run a flow built with Power Automate for desktop action.
Create a connection
If you didn't already set up a connection to your machine, you need to create one. If you already have a connection, you can skip this section and go to the Enter Inputs section.
Enter a Connection Name. For this example, the connection is named DesktopFlowConnection.
For the Connect field, select Connect with sign in - Attended.
For the Machine or Machine Group, select your machine. If you don't see your machine, select the refresh button next to Search. If your machine still doesn't come up, check the Power Automate Machine runtime app and make sure your computer is connected to the same environment.
Select Sign in and a pop up appears for you to sign in with your credentials.
[!div class="mx-imgBorder"]
Enter inputs
Once a connection is created, you're redirected to the Run a flow built with Power Automate for desktop action to enter inputs.
For the Desktop Flow field, select Invoicing.
For the Run Mode, select Attended (runs when you're signed in).
Once you choose your desktop flow, the input variables that you defined in your desktop flow are requested. For now, we can put some placeholders in these fields, though you can use information from the email or attachments. You can also use the output variables that are provided by the desktop flow in later actions.
For the Account enter WingTip Toys.
For the Amount, enter 200.00.
For the Contact, enter b.friday@wingtiptoys.com.
For the Date, enter today's date.
Now that you set up your desktop connection and created a cloud flow to trigger the desktop flow and provide inputs, you can test that everything is functioning properly.