Skip to main content

Object Explorer and automations

Object Explorer and automations

Automation development drives its structure from the Object Explorer. The Object Explorer displays interrogated application controls as well as .NET controls added to a windows form. Through this access, a developer has access to the object's properties, events, and methods to connect a logical flow that reproduces the manual process.

In automations, you can change the text value of a field, add and select an item from a combo box, determine if the user interacted with an application, or perform a click on a button. Pega Robot Studio™ provides these options to the developer in the Object Inspector of the Object Explorer.

The Object Inspector provides access to the object's properties, events, and methods. In the following Object Inspector image, the three buttons -- Show Properties Only (wrench), Show Events Only (lightning bolt), and Show Methods Only (box) - display an object's properties, events, and methods when clicked. The fourth button, Configure type (books), provides access to a library of all properties, events, and methods for a specific object type.

Object inspector

Automations usually begin with an object's event, meaning that the automation does not begin until a window displays or a user clicks a button. Design blocks are the items added to an automation.

When you add the logical sequence of the design blocks to an automation, the automation links denote the executable logic of the design blocks. Each design block has an input port and an output port. Green design blocks are events. Blue design blocks are properties. Light blue blocks are methods. Studio provides linking to pass coding logic and data values. Studio denotes execution automation links in yellow and data automation links in blue. The following image shows an automation example.

c07p2e1 01

The automation begins only when the application creates the CRMfrmLogin window. The automation performs the click on the CRMbtnLogin, waiting for the application to create the CRMbtnUser1, and when the button is available, the automation performs a click.

Target Creation

When creating automations you must consider is the amount of time a web page spends to load or the wait time for an application to respond. For instance, some web applications load quickly, while others do not. Numerous variables can cause this variance, such as time of day, number of users, and background application processing.

When automating actions that interact with applications and their controls, you should make sure the target pages or windows and their controls are available before your automation sends data or responds to events on the controls. Studio provides properties, events, and methods to make sure targets are available and matched.

Created event

When Pega Robot Studio™ matches a target, the Created event for the object triggers. For example, in the CRM_E_CRMfrmLogin automation image, when the CRM Login is fully loaded, a Created event triggers. Remember the Created event for any object triggers when the object matches, meaning navigating back to a previous page or window retriggers the Created event for all interrogated objects on that page or window.

IsCreated property

This property is False until the object's Created event triggers. Returning to the example of the CRM_E_CRMfrmLogin automation, the CRMfrmLogin window IsCreated property turns True when it matches the Studio match rules for the object. When you click the Login button, the window un-matches, and the IsCreated property returns to False. The IsCreated property is one property that a developer cannot modify through an automation.

WaitForCreate method

The WaitForCreate method sets up automation logic to wait until the Created event triggers for an object before proceeding to the next step of the automation. The method provides a Boolean result of the Created event. If the Created event occurs within the wait time, the automation continues through the True logic. If it does not occur within the wait time, the automation continues through the False logic.

If the WaitForCreate method is not used, all objects have an implicit wait of 30000 milliseconds (30 seconds) by default. This means that Studio waits until the Created event triggers for an object. After 30 seconds, the next step in the automation is attempted.

Using the implicit wait time is not the preferred application of the logic. You should use the method because it provides logic to the automation through the method's Boolean result.


This Topic is available in the following Module:

If you are having problems with your training, please review the Pega Academy Support FAQs.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Academy has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice