Change area Version 1 (Java)

Action group: Base actions, subgroup: General


Description

Action returns rectangle area, that has been changed according to provided parameters. Width, length and coordinates of the upper left corner can be changed

Action icon

 

Settings of parameters 

PropertyDescriptionTypeFilling example

Mandatory 

field

Parameters
Rectangle AreaRectangle AreaRectangle Location X: 796 Y: 504; 488*210Yes
Left upper corner X-axis shiftShift along the x-axis of the left upper corner of the rectangle areaNumeric 234No
Left upper corner Y-axis shiftShift along the y-axis of the left upper corner of the rectangle areaNumeric -50No
Height changeHeight change of the rectangle areaNumeric 10No
Width changeWidth change of the rectangle areaNumeric -98No
Results
Changed rectangle areaVariable in which the coordinates,length and width of the changed rectangle area will be writtenRectangle Location

Special conditions of use

If no value is entered in the optional parameter field, the coordinate value of the corresponding axis, height or width is saved to the result unchanged.

Example of use 

Task

You need to retrieve individual elements from the image and save them to a folder.


Solution

Use the "Change area" and "Take screenshot" actions.

Implementation

  1. Create a variable with arbitrary area dimensions.


  2. Transfer the "Change area" action to the workspace.


  3. Set the parameters of the "Change area" action.
    1. In the "Rectangle area" field, add the created variable with the area dimensions.
    2. Enter the required values in the remaining fields.


  4. Move the "Take screenshot" action to the workspace.


  5. Set the parameters of the "Take screenshot" action.
    1. In the "Folder" field, add a previously created folder.
    2. Select an arbitrary file name and format for the screenshot.
    3. In the "Type" field, select the "Coordinates" option.
    4. In the "Arbitrary rectangular area" field, add the result of the "Change area" action.

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

Result

The program robot worked successfully. The robot took a screenshot of the changed area parameters and saved the result to the folder.

  • Нет меток