How to Create a Repeatable Loop
Hi, I just downloaded Sikuli 2 days ago. The Language and constructs are all very new to me, I am not familiar with programming code. But the potential of this type of program is great for me, if I can learn it. For now, I have a very simple question.
I have a program that runs overnight on my computer, but within the program the publisher has some unavoidable pop-ups that must be clicked to close or else the program is stagnant all night until I awake in the morning.
I attempted to make a Sikuli script to recognize a unique image within the pop-ups and then click to close the pop-up. The script works, but it only works for 1 occurrence. I want it to run continuously overnight to close the pop-ups as they appear several times during the night.
Here is the script I wrote
1) wait (image, FOREVER)
2) click (image)
Right now once it clicks to close the pop-up, the sikuli program stops.
I would like it to Wait until the Image appears
then to perform the function of clicking to close the pop-up
then to go back to waiting until the next time the pop-up appears
to perform the function of clicking to close again
repeat
repeat
and so on....
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- SikuliX Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- max
- Solved:
- Last query:
- Last reply: