My macro seems to stop after only 1 iteration. The pixel in question is normally [R=221, G=74, B=112]. I want to keep clicking a button 100 times again until it changes. However, it only clicks the first 100 times, and then stops. If as a test I change the pixel to some other color, it properly clicks 100 times, and then clicks the 400|600 before exiting.
What am I doing wrong?
15 | FOR | I | = | 0 TO 100 | NEXT
20 | 1000 | 350 | 25 | Left Click
25 | FOR | NEXT
30 | IF | PIXEL COLOR | Color [R=221, G=74, B=112]::At Location [X:450 Y:600] | IS THE SAME | GOTO MACRO LINE | 15
I cannot seem to replicate this problem, I noticed your lines are 15,20,25,30,35. Can I ask if you have manually changed these line number? Because I feel that could be causing a issue, to correct this - click on one of your lines and right click then 'Relist Rows', you will have to redirect your GoTo Macro Line after. But personally I use labels all the time so that if at a future point I update the macro, I don't have to remember which lines were pointing to a particular line.
To confirm, the action GoTo Macro Line will not see a line that has been manually changed to a different number. If you have the first line as 15 but tell GoTo Macro Line 1, the first line will still be selected.