Click mouse in current position

I’m a UI.Vision noob, but a long-time developer. I’m working on filling out a form and just need to issue a xclick in the mouse’s current position. I’ve already got the mouse in the right position. It needs to be quick. XClickTextRelative is too slow. By the time the OCR completes, the button is disabled again. Is there any way to issue a simple XClick at the current position? Or even save the mouse coordinates and then issue XClick at the saved mouse coordinates?

You can use XClick with coordinates, too. Example: XCLICK | 23,103

The coordinates of a previous XCLICK are available in these built-in variables:

  • ${OCRX},${OCRY} for XClickText/XMoveText
  • ${IMAGEX},${IMAGE} for XClick/XMove

So if you already moved the mouse to the right place with XMoveText, you can then use XClick | ${OCRX},${OCRY} to click again on the same spot. This avoids doing OCR or image recognition again.

That’s awesome! I didn’t know that. Thank you!