Сравнение версий

Ключ

  • Эта строка добавлена.
  • Эта строка удалена.
  • Изменено форматирование.

In order to search by used variables you need to:

  1. Install the platform.

  2. Open the studio.

  3. Create a robot.

A prerequisite is that variables and other resources must be created in the robot project.

The resource can be used as a parameter or a result depending on the needs , directly or as a property (e.g. winelement.xPath).

To do this, you need to:

On the top panel, click on the "Search" (Magnifier) button - a search bar is displayed, inside of which it says "Searching for resource..." and a magnifier icon.

  • In the top panel of the Studio, click the search icon.

  • Three tabs are displayed: Actions, Resources and Contexts

  • Select the Resources tab. The Variables resource view.

  • The Resources tab is located between Actions and Contexts

  • In the list of variables, expand the list of actions where it is used.

  • Click on the used action.

Let's consider the following steps sequentially for searching for the used variables.


1. Display the Resources tab and its search bar

Image Added

1.1 Select the Resources tab.

Image Added

2 .  Creating resources 2.1 Creating a variable.

Image Added

2.2 Creating a "file" resource.

Image Added

2.3 Creating a web-element resource.

Image Added

where:

  • 1 – Resources tab

  • 2 – Create resource button

  • 3 – Input field for the attribute that the robot will refer to

  • 4 – Drop-down list where we will select the attribute

2.4 Creating a win-element resource

Image Added

To create a win element you need to launch the spy. In the spy it is necessary to select the capture button and then already point at the necessary win element and by pressing the button LCTRL and LMB we capture the necessary element. After that we press the save button.

3.  There are resources in the project, but the resources are not used anywhere

Enter 1 in the "Resources" field

Image Added

Enter “Variable 1”

Image Added

Enter "File"

Image Added

Enter "Web"

Image Added

Enter " Win"

Image Added

Since the resources are not used anywhere, there is no drop-down list near the resource record (no "Expand" button) and nothing happens when you click on the resource record itself.

4 . Searching for actions by Variables in use

4.1 . Add two actions " Reverse 1" and "Reverse 2"

Add two actions " Reverse 1" and "Reverse 2".


In the " Reverse 1" action, specify the resource "Variable 1" as the input parameter "Text".


In the " Reverse 2" action, specify the "Variable 1" resource as the output parameter.

Image Added

4.2. Click on the "Search" ( Magnifier) button on the top panel, select the "Resources" tab and clear the search bar (see in section 1.1)

4.3. Activate the search by entering the word "Variable" into the search box

4.4. Expand the drop-down list of the "Variable" resource

*4.5. Click on each item in the drop-down list: " Reverse 1" and "Reverse 2" *

Image Added

If we click on " Reverse 1", "Reverse 2", we will be taken to the action itself, where this variable is used.

5. Search actions by used Files

5.1. Add two actions "Read text file 1" and "Open document 1" (for example, from the "Word" group).

Image Added

5.2. In "Read text file 1" specify the resource "File 1" as input parameter

Image Added

5.3 In "Open document 1" specify the resource "File 1" as input parameter

Image Added

5.4. On the top panel, click on the "Search" button (Magnifier), select the "Resources" tab and clear the search bar

5.5. Activate the search by typing the word "File" into the search box

5.6. Expand the drop-down list for the "File 1" resource

5.7. Click on each item in the drop-down list: ""Read text file 1" and "Open document 1".

Image Added

When you click on a line with the "Read text file 1" entry, the Studio scrolls through the script and focuses on the "Read text file 1" action, the properties panel displays the properties of the "Read text file 1" action

When you click on the row with the "Open document 1" entry, the studio scrolls through the script and focuses on the "Open document 1" action, and the properties panel displays the properties of the "Open document 1" action.

6 . Search for actions by the Web-elements used

6.1. Add two actions "Send Text 1" and "Send Click 1".

Image Added

6.2 . In "Send text 1", specify the resource "Web-element 1" as the input parameter.

Image Added

6.3. In "Send click 1", specify the resource "Web-element 1" as the input parameter.

Image Added

6.4. On the top panel, click the "Search" (Magnifier) button, select the "Resources" tab, and clear the search bar.

6.5. Activate the search by entering the word "Web-element".

6.6. Expand the drop-down list for the resource "Web-element 1".

6.7. Click on each item in the drop-down list: "Send text 1" and "Send click 1".

Image Added

When you click on a row with a "Send text 1" entry, the studio scrolls through the script and focuses on the "Send text 1" action, the properties panel displays the properties of the "Send text 1" action When you click on a row with a "Send click 1" entry, the studio scrolls through the script and focuses on the "Send click 1" action, the properties panel displays the properties of the "Send click 1" action

7 . Search for actions by the Win-elements used

7.1. Add two actions "Window focus element 1" and "Get element text 1".

Image Added

7.2. In "Window focus element 1", specify the resource "Win-element 1" as the input parameter.

Image Added

7.3. In "Get element text 1", specify the resource "Win-element 1" as the input parameter.

Image Added

7.4 . On the top panel, click on the Search (Magnifier) button, select the Resources tab, and clear the search bar.

*7.5 . Activate the search by typing the word "Win-element" into the search box.

*7.6 . Expand the drop-down list at the resource " Win-element".

7.7. Click on each item in the drop-down list: "Window focus element 1" and "Get element text 1".

Image Added

When you click on the line with the entry "Window focus element 1", the studio scrolls through the script and focuses on the action "Window focus element 1". The properties panel displays the properties of the "Window focus element 1" action.*

When you click on the row with the "Get element text 1" entry the studio scrolls through the script and focuses on the "Get element text 1" action and the properties of the "Get element text 1" action are displayed in the properties panel.

8 . Search for actions by the resource properties used

8.1. Add the "Convert data 1" and "Replace matches 1" actions.

Image Added

8.2 . In the "Convert Data 1" action, specify the resource property "Win-element 1" : "Win-element 1.WindowName" as the input parameter.

Image Added

8.3. In the "Replace Matches 1" action, specify the resource property " Win-element 1" : "Win-element 1.Definition" as the output parameter.

Image Added

8.4. On the top panel, click on the "Search" (Magnifier) button, select the "Resources" tab.

*8.5. Activate the search by entering " Win-element" into the search.

8.6 . Expand the drop-down list for the resource " Win-element 1".

Image Added

8.7 . Add actions "Convert data 2" and "Replace matches 2".

Image Added

8.8. In the "Convert data 2" action, specify the "Web-element 1" resource property : "Web-element 1.XPath" as the input parameter.

Image Added

8.9. In the "Replace matches 2" action, specify the resource property "Web-element 1" : "Web-element 1.DisplayName" as the output parameter.

Image Added

8.10. On the top panel, click the Search button (Magnifier), select the Resources tab. Activate the search by entering "Web-element" Expand the drop-down list for the resource "Web-element 1".

Image Added

8.11. On the top panel, click the Search button (Magnifier), select the Resources tab. Activate the search by entering "File" in it Expand the drop-down list for the resource "File 1" on the "Files" tab.

Image Added

8.12. On the top panel, click on the "Search" button (Magnifier), select the "Resources" tab. Activate the search by entering the number "1" in it Expand the drop-down list for each of the resources.

Image Added

9 .  Checking with several resources of the same type

9.1. Create several more resources (e.g., 5-10 more each):

  • several variables.

  • several file resources.

  • several web-elements.

  • several win-elements.

9.2. Add many different actions to the script, in the parameters and results of which you specify the newly created resources and the properties of these resources (this applies to all resources except variables).

9.3. On the top panel, click on the "Search" button (Magnifier), select the "Resources" tab and check each of the resource types by activating the search by typing the resource name.

Image Added

10 . Re-open the studio and again check each tab on the Resources tab in the Search functionality

11. Checking when resources of different types are used simultaneously in one action

11.1. Add the "Add element 1" action to the script, increase the number of parameters.

Image Added

11.2. In the "Object" parameter, specify the resource "Variable 1".

In the "Object 1" parameter, specify the "File 1" resource property : "File 1.Value".

In the "Object 2" parameter, specify the "Web-element 1" resource property : "Web-element 1.XPath".

In the "Object 3" parameter, specify the resource property "Web-element 1" : "Web-element 1.Definition".

Image Added

11.3. On the top panel, click on the "Search" (Magnifier) button, select the "Resources" tab, and check each resource by activating the search by typing the resource name.

Image Added

12. Search by partial match

12.1. In the Studio settings in the "Exact match search" field uncheck the box, if checked.

Image Added

12.2. Enter in the search field: "Variable"

12.3. Enter in the search field: "File"

12.4. Enter in the search field: "Web-element"

12.5. Enter in the search field: "Win-element"

13. Deleting from parameters and results of resource actions and resource properties

13.1. Remove all references to resources from all parameters and action results.

13.2 . On the top panel click on the "Search" button ( Magnifier), select the "Resources" tab and check each resource by activating the search by resource name. There is a bug: if you remove variables from actions and search in resources, it will still show that the variable in the action is used, although this variable is removed from the action. Only reloading the studio helps.

Image Added

14. Deleting actions that use resources and their properties

14.1. Specify resources and their properties in the parameters and results of actions..

14.2 .Delete some actions in which resources are used.

14.3. In the top panel, click on the "Search" button (Magnifier), select the "Resources" tab and check each resource by activating the search by resource name.

Let's delete the "Read text file" action.

Image Added

Result

Image Added

15. Deleting resources

15.1. Specify resources and their properties in the action parameters and results.

15.2. Delete all resources.

15.3 .In the top panel, click on the Search button ( Magnifier), select the Resources tab and check each resource by activating the search by resource name.

Let's remove the File parameter and check.

Image Added

Result


As you can see the search did not yield any results as the resource has been removed.