Skip to main content

Move mouse to image

Sophie avatar
Written by Sophie
Updated over 2 weeks ago

Definition and Usage

Moves the mouse over an image found on the screen or in a window. This action allows you to position the mouse cursor at a specific location by identifying a target image on the screen.


Parameter Values

Input parameters

Parameter

Description

Possible Values

Required

Options / Notes

Search scope

Specify the scope to search for the target image: entire screen, window object, or currently active window

Entire screen, Specific window, Currently active window

Yes

When "Specific window" is selected, you must provide a window object

Window

Select a window object that was obtained earlier

Any valid window object

Only when "Specific window" is selected

This parameter appears only when "Specific window" is selected

Select image

The image to locate on the screen or within the selected window

Any valid image

Yes

Use the Capture button to select an image from the screen

Advanced settings

Parameter

Description

Possible Values

Required

Options / Notes

Cursor position

Select where the mouse cursor should point on the image

Center of the image or custom position

Yes

Default: center of the image; can be adjusted with horizontal and vertical offsets

Match mode

Color matching uses full color comparison; grayscale matching compares grayscale images and is faster

Color matching, Grayscale matching

Yes

Grayscale matching is faster but may be less accurate

Similarity (%)

Sets the similarity threshold (%) for image matching

0-100

Yes

Recommended: 80%; lower values may cause false matches, higher values require more exact matches

Wait after execution (s)

Wait time (seconds) after mouse movement

Any positive number

Yes

Default: 1 second

Timeout (s)

Set the maximum time to wait for the image to appear

Any positive number

Yes

Default: 20 seconds; action fails if image isn't found within this time

Error handling

Parameter Name

Description

Throw error & stop

When an error occurs, the action will trigger an error and stop the execution of the entire app.

Retry command

If an error occurs, the action will retry the command in an attempt to resolve the issue and continue the process.

Ignore error & continue

When an error occurs, the action will be ignored, and the workflow will continue without interruption.

Variables produced

This action doesn't produce any variables.


Using Variables in Conditions

Fields marked with {x} icon support variable insertion. You can use variables created in previous steps to dynamically determine parameter values. For example, you could use a variable to set the similarity percentage or timeout duration based on specific conditions in your workflow.


Notes

  • Before using this command, ensure that the target image is visible and recognizable on the screen.

  • Image recognition can be affected by screen resolution, color settings, and visual elements that may change between runs.

  • For better reliability, choose distinctive images with unique visual features rather than generic or common UI elements.

  • If the target image is not found within the specified timeout period, the command will fail according to the selected error handling option.

  • Consider using grayscale matching for better performance when color is not critical for identification.

Did this answer your question?