Activities
latest
false
Banner background image
UI Automation Activities
Last updated Apr 26, 2024

PREVIEW
Set Runtime Browser

UiPath.UIAutomationNext.Activities.NSetRuntimeBrowser

Description

Sets the currently active runtime browser.

This configuration remains in effect for both Modern and Classic activities until either the execution ends or another Set Runtime Browser activity is encountered within the same project.

This activity must be added inside a Use Application/Browser activity.

To use this activity outside a Use Application/Browser activity, you need to provide an Input element.

Project compatibility

Windows - Legacy | Windows

Windows - Legacy, Windows configuration

Designer panel
  • Browser type - Choose the type of browser you want to be used at runtime. This property accepts only NBrowserType variables or arguments.
    • None - Enum value: NBrowserType.None. The Runtime browser project setting (Project Settings > UI Automation Modern > Application/Browser) is no longer overridden.
    • DefaultOSBrowser - Enum value: DefaultSystemBrowser.BrowserType. Uses the default browser set on the target machine.
    • Chrome - Enum value: NBrowserType.Chrome. Uses the Google Chrome browser.
    • Edge - Enum value: NBrowserType.Edge. Uses the Microsoft Edge browser.
    • Firefox - Enum value: NBrowserType.Firefox. Uses the Mozilla Firefox browser.
Properties panel

Common

  • Continue on error - Specifies if the automation should continue even when the activity throws an error. This field only supports Boolean values (True, False). The default value is False. As a result, if the field is blank and an error is thrown, the execution of the project stops. If the value is set to True, the execution of the project continues regardless of any error.
  • Delay after - Delay (in seconds) between the time this activity is completed and the time the next activity begins any operations. The default value is 0.3 seconds. Adding a delay between activities ensures that one activity has enough time to complete before the next activity begins.

  • Delay before - Delay (in seconds) between the time the previous activity is completed and the time this activity begins performing any operations. The default value is 0.2 seconds. Adding a delay between activities ensures that one activity has enough time to complete before the next activity begins.

  • Display name - The name displayed for the activity in the Designer panel. A display name is automatically generated when you indicate a target.

  • Timeout - Specify the amount of time (in seconds) to wait for the activity to be executed before throwing an error. The default value is 30 seconds.

Input

  • Browser type - Choose the type of browser you want to be used at runtime. This property accepts only NBrowserType variables or arguments.
    • None - Enum value: NBrowserType.None. The Runtime browser project setting (Project Settings > UI Automation Modern > Application/Browser) is no longer overridden.
    • DefaultOSBrowser - Enum value: DefaultSystemBrowser.BrowserType. Uses the default browser set on the target machine.
    • Chrome - Enum value: NBrowserType.Chrome. Uses the Google Chrome browser.
    • Edge - Enum value: NBrowserType.Edge. Uses the Microsoft Edge browser.
    • Firefox - Enum value: NBrowserType.Firefox. Uses the Mozilla Firefox browser.

Misc

  • Private - If selected, the values of variables and arguments are no longer logged at Verbose level. This field supports only Boolean (True, False) values. The default value is False.

Handling order

The order used for setting the browser type used at runtime is the following:
  1. Through the Set Runtime Browser activity.
  2. Through the Runtime browser project setting (Project Settings > UI Automation Modern > Application/Browser).
  3. Through the Use Application/Browser activity or other UI Automation activities.

Configure the browser type from Orchestrator

Orchestrator has built-in support for a limited number of base data types, such as string, integer, boolean, etc. For more details, you can check out the About input and output arguments page.
For data types that are not supported by default in Orchestrator, you must use a JSON representation of that value. For instance, in the case of enums, the JSON representation is either the integer value of the enum value or the string value.
To configure an NBrowserType argument in Orchestrator, you need to follow the steps below:
  1. Create an input argument in your Studio project, for example in_RuntimeBrowser.
  2. Set the Browser type property of the Set Runtime Browser activity with the value of the argument.
  3. Publish your project to Orchestrator.
  4. In Orchestrator, go to Automations > Processes > Add Process.
  5. Under Runtime Arguments, provide a value for the in_RuntimeBrowser argument. You need to specify the browser type in this format: "BrowserName". For example: "Edge". Quotes need to be included. The following browser options are supported:
    • "None"
    • "Chrome"
    • "Edge"
    • "Firefox"
  6. Save the value for the argument. After creating the process, the value determines the browser type used by the automation.

Was this page helpful?

Get The Help You Need
Learning RPA - Automation Courses
UiPath Community Forum
Uipath Logo White
Trust and Security
© 2005-2024 UiPath. All rights reserved.