Click on Cell
Verb: clickGrid
Clicks on a cell in a grid.
Syntax
clickGrid --grid(ImageGrid) --row(Numeric) --column(Numeric)
Inputs
Script | Designer | Required | AcceptedTypes | Description |
---|---|---|---|---|
--grid | Grid | Required | Image Grid | Grid in which a cell is clicked on.
The grid informed in this parameter must be mapped. |
--row | Row | Required | Number | Row where the cell that should be clicked is located at. |
--column | Column | Required | Number | Column where the cell that should be clicked is located at.
Numbers represent the columns in order from left to right. |
Example
An open Excel window is awaited with the Wait for Window to Appear command and focused on the foreground with Focus Window. The grid is mapped and the Click on Cell command clicks on the first cell of the second and third rows.
defVar --name window --type Window
defVar --name window --type Window
defVar --name success --type Boolean
defVar --name mappedTable --type ImageGrid
openFile --file "tableExcelCompanyCity.xlsx"
waitWindow --title "tableExcelCompanyCity.xlsx - Excel" --classname XLMAIN --processname EXCEL window=value success=success
mapGrid --columnmappings "28-91;91-151;151-219;219-282;282-346;346-408;408-475;475-537;537-604;604-666;666-730;730-793;793-861;861-919;919-985;985-1050;" --selector "IdAndName" --id Grid --name Grid mappedTable=value
focusWindow --window ${window}
clickGrid --grid ${mappedTable} --row 2 --column 1
clickGrid --grid ${mappedTable} --row 3 --column 1
delay --timeout 00:00:03
// Waits for opened Excel window, maps window grid.
// Focuses on the foreground window for demonstration.
// Click on the cells located in the first column, second and third row.
// Waits 3 seconds and ends execution.
For the correct operation of the command, it is necessary that, after downloading the file, its path is inserted in the Path parameter of the Run command.