Button doesn't get clicked because of different stage color on hover over

I have an action to click at a found image, which is a button, that can't be clicked like a normal button.
Screen Shot 2022-06-19 at 10.26.24 AM

Now when I hover over, the background color of the button changes a little bit, so KM isn't clicking it.
Screen Shot 2022-06-19 at 10.27.04 AM

I guess KM is not fast enough to click compared to the effect of the button changing the background color, so it doesn't identify it and stops.

Any idea how to workaround this?
For now I had to have an action to just move to one of the corners of the button to make it change color then another action to find the image with the new background color and click it.

Any better solution?

Is there a reason for the second image detection? Can you not just use a "Move and Click, found image's center" mouse action with the first image? If that doesn't work because sometimes the pointer is over the button, changing the colour, try preceding the action with one that moves the pointer to somewhere definitely off the button (like into the menu bar!)


Here's another thing you could try:

Also, if that button is always in the same screen location, you can click relative to the front window's corner without using found images at all.

1 Like

The only way I can see this being a problem is if your mouse might already be over the button, and thus the button is not recognised because it is already highlighted.

The fact that it highlights while Keyboard Maestro clicks it should not affect Keyboard Maestro detecting it, if it has already detected its location.

Very rarely applications require the button to highlight before being clicked, in which case you may want to do as noisneil suggested and move the mouse over the button, then maybe pause, then click at the current location.