Connect to an open browser Version 7 (Java)

Action group: Browsers 


Description

The action connects to a pre-opened browser window. It does not connect to windows that other robots have opened or connected to.


Action icon

Parameters

Input parameters

  1. Browser - The name of the browser to connect to. For example: Chrome.
  2. Address - The default IP to connect to. The default value is localhost.
  3. Port - The port where the connection is coming from. The default value is 9222/.

Output parameters

The output is the browser instance that the actions will work with.

Settings

PropertyDescriptionTypeFilling exampleMandatory field
Parameters
BrowserThe name of the browser to connect to.Robin.String
Yes
AddressIP address for connection. Default is localhost.Robin.String
No
PortIP address for connection. Default is 9222.Robin.Numeric
No
Results
ContextThe browser instance that actions will work with.Robin.SeleniumBrowser context

Special conditions of use 

Parameters may vary depending on the version.

The RobinRecorder 0.2 browser extension must be installed beforehand.

The following steps must be performed for the action to work correctly:

  1. Right-click on the browser shortcut and add --remote-debugging-port=9222 to the Object field
    Click on the "OK" button.

  2. Go to Task manager and check that no Chromium-based browsers are running (except the required one). 
    If they are running, close them. 
    List of these browsers: https://ru.wikipedia.org/wiki/%D0%91%D1%80%D0%B0%D1%83%D0%B7%D0%B5%D1%80%D1%8B_%D0%BD%D0%B0_%D0%B1%D0%B0%D0%B7%D0%B5_Chromium
  3. Install web drivers for Chrome and Yandex browsers. Place them, for example, in the root of the C drive.
    You can download them by following the links: https://github.com/yandex/YandexDriver/releases и https://chromedriver.chromium.org/
  4. Verify that there is an env.cfg file in the .robin folder with the specified drivers and their versions. 
  5. The browser must be minimized before running the action. 
  6. If there are multiple tabs open in a browser, the action can connect to any of them. If multiple browsers are open, the action connects to the instance that is launched first.

Additionally:

  1. If multiple tabs are open, the robot can connect to any tab. 
  2. There will be no robot-controlled notification in the browser window.
  3. After the robot finishes, the browser page will remain open unless some other action is taken. 

Example of use  

Task

Connect to your Chrome browser and follow the link. 

Solution

Use the "Connect to an open browser", "Navigate" actions. 

Implementation

  1. Assemble a robot scheme consisting of the actions: "Connect to an open browser", "Navigate". 
  2. Set a parameters for the "Connect to open browser" action  
  3. Customize the parameters of the "Navigate" action. In the "Context" field, select the context of the "Connect to an open browser" action. In the "Address" field, specify the address you want to go to. Make the "In a new tab?" field active.

  4. Click on the "Start" button in the top panel. 

Result

The program robot completed successfully. Connection to an open browser and clicking on the link was performed. 

Browser view after clicking on the link. 

 


  • Нет меток