Use case: using a StartMyDay service in an automation
The Start My Day feature of Pega Robot Studio has several methods and events you can use to launch the applications and processes you use to begin your workday.
This innovation lets you specify activities a Robot Runtime or Agile Desktop user is presented with when he or she first starts Runtime/Agile Desktop. This list can include non‐Pega programs and URLs, as well as Pega Robot Studio solutions. Users can use the Manage Applications dialog to prioritize the order in which applications are launched to maximize their readiness.
In addition, each Runtime/Agile Desktop user can add to and remove from the list of processes to be started by Runtime/Agile Desktop. The items on the list are specific to the user.
To enable an application to be used for StartMyDay, first add the application.
- From the Project Explorer, select Add > Application.
- Set the application name to use in the automation, and set the Path to the
executable for the app.
- Click Add.
Result: The application opens.
- In the Properties Grid to the right, scroll down to the StartMyDay properties.
- Select StartMyDay as the StartMethod and
Automatic as the StartMyDay property.
- In the Toolbox to the left, open the Accelerators folder
and then the StartMyDay folder.
- Start by dragging a StartMyDay method to the Automation
- Next, drag an AddExeApplication to the Automation
Surface.We already added one application, when we started our project. We can add another using a StartMyDay method. For this use case, you can use any executable that you have installed and know the path for. We're just going to launch the apps, and not perform any tasks in them.
- Define the friendlyName of the app and its path.Now let's pause and link up these automation blocks, to establish a workflow.
- In the StartMyDay automation block, click the small orange circle to the right
of the StartMyDay text and drag the arrow to the right,
to the orange circle to the left of the AddExeApplication
block. Now that we've added these apps, let's start them up.
- Click and drag a StartApplications method to the right of the existing workflow.
- Click on the first FriendlyName field and enter the name of the Windows app you added in the first AddExeApplication block (Notepad in our example.)
- Click on the second FriendlyName field in the StartApplications block and add the FriendlyName you gave to this second app.
- Create the workflow link leading to this automation block.The workflow should now look like this:Since we're launching two apps in our StartMyDay automation, we need to make sure we can see both. StartMyDay lets you define exactly where apps will display on the desktop.
- Click and drag the SetApplicationPositionAndSize method; place it underneath the current workflow, at the left side of the screen.
- Set the values for each position field as follows.
Position 1st App Values 2nd App Values Left 200 1000 Top 200 200 Width 500 500 Height 600 600These position values will place the first app (Notepad) to the left of the desktop, and the second app (BankerInsight) to the right of the first app. Both apps will be the same height and width.
- Now connect the workflow arrow to the position and size block you just
Result: Your automation workflow should look similar to the following:
- Select the Test button.
Result: The automation runs, opening the two applications and placing them side by side. Previous topic StartMyDay properties, methods, and events Next topic Variables