Reads the current mouse pointer position in desktop pixels.
Sample the mouse position when the block fires and connect its two numbers to another desktop block in the same workflow.
Inputs and settings
Connect fire to the step at which you want to sample the pointer. This block has no settings.
Outputs
| ID | Type | Meaning |
|---|---|---|
x | number | Horizontal desktop pixel position measured from the left edge of the primary display. |
y | number | Vertical desktop pixel position measured from the top edge of the primary display. |
fire | fire | Fires after a successful measurement. |
What happens when it runs
This block runs on this computer through the installed add-on. Sampling leaves the pointer in place. Connect X and Y to Move Mouse to restore the sampled position later in the same run. Displays to the left of or above the primary display can yield negative coordinates.
Error handling
Windows needs access to an unlocked interactive desktop. If the pointer cannot be read, execution stops at this block.
