Chapters:
Intro 00:00
Tip #1 00:12
Tip #2 02:22
Tip #3 03:30
Tip #4 04:44
Tip #5 06:21
Tip #6 08:33
Tip #7 09:58
Tip #8 11:23
Tip #9 12:26
Tip #10 13:37
Very nice video.
As a person who uses "Find Image" a lot, I would like to point out a point where the macro is very slightly risky.
That's because the "Log in" button on the web page changes colours when you move your mouse over it. Therefore, there is a small chance that the Find Image could fail to find the image (if the mouse is already over the image when you trigger the macro.) If it fails to find the image, it won't perform the "click." In this case, however, the Fuzz Factor bar is set to 15% (which is the default, I think), and when I tested it for this website, the change in colour was only a 15% change in the image, so there won't be a problem in this macro (barely), but your results may vary.
In this case, one way to solve the problem is to just increase the fuzz factor to 25%. That will probably work fine in this case. However for people who want to know how to more safely solve this potential problem, there are other solutions. Here's what I would do:
In the above code, you can see a loop which will keep checking for the existence of two or more different images (you may not notice the difference, but in the above code, the first image is lighter than the second image.) Once the value of LoginButton contains a value, the loop will exit. Then you can click the mouse at the location of the LoginButton.
In this case, my solution may be overkill because increasing the fuzz factor should be adequate. However there are some cases where the fuzz factor won't be enough. For example, some websites may support a dark mode and a light mode (this website does, but neither mode changes the colour of the Log in button.) If the button changes colours completely for dark mode, then my approach may be required.
I'd go further and say that there are better methods than using found images for pressing buttons, including the "Press a button" action.
Great point. Of course, there are some things that don't register as buttons, like items in the macOS System Menu.
But you do know those things... I think you must have meant "I wish I had known this”.
(I grind my teeth every time I encounter this mistake on YouTube, and I don’t want to have to buy dentures..! ).
Haha, noted for next time.
Thank you in advance for the molar consideration.