UiPath Activities

The UiPath Activities Guide

Web Browsing

The example below explains how to automate the action of browsing a webpage by highlighting and showing the content of all items from the header menu. It presents activities such as Open Browser, Highlight, and Hover. You can find these activities in the UiPath.UIAutomation.Activities package.

This is how the automation process can be built:

  1. Open Studio and create a new Process.
  2. Open Internet Explorer and navigate to www.uipath.com.
  3. Drag a Sequence container in the Workflow Designer.
    • Create the following variable:
Variable Name
Variable Type
Default Value

menuItems

System.Collections.Generic.IEnumerable<UiPath.Core.UiElement>

-

  1. Drag an Open Browser activity inside the Sequence container.
    • Add the browser's path in the Url field, for this example being www.uipath.com.
  2. Drag a Find Children activity inside the Do container of the Open Browser activity.
    • Inside the activity, click the Indicate on screen option. Select the header of the menu like in the following screenshot:
      Test
    • In the Properties panel, add the variable menuItems in the Children field.
  3. Drag a For Each activity and place it below the Find Children activity.
    • Add the value item in the ForEach field and the variable menuItems in the Values field.
  4. Select the Body container of the For Each activity and create the following variable:
Variable Name
Variable Type
Default Value

aanameValue

String

-

  1. Place a Highlight activity inside the Body container.
    • In the Properties panel, select the option Target from the Target drop-down list.
    • Add the value item in the Element field. This value selects and highlights each option available in the menu.
    • Select the option Coral from the Color drop-down list. This specifies what color to use for the highlight.
  2. Drag a Hover activity below the Highlight activity.
    • In the Properties panel, add the value item in the Element field. This value hovers all options available on the menu.
    • Select the check box for the SendWindowMessages option. When this option is selected, the hover command is executed by sending a specific message to the target application.
  3. Place a Hover activity below the For Each activity.
    • Inside the activity, click the Indicate element inside browser option. Select the header of the menu like in the following GIF:
      1
    • In the Properties panel, select the check box for the SendWindowMessages option. When this option is selected, the hover command is executed by sending a specific message to the target application.
  4. Drag a Close Tab activity below the last Hover activity.
    • Your workflow should look like in the following screenshot:
  1. Run the process. A new Internet Explorer is opened and navigates to the www.uipath.com address, where it highlights and shows the content of all items from the header menu.
    Your workflow should look like in the following screenshot:

Updated about a month ago


Web Browsing


Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.