How to keep on rightclicking, until image appears?

Asked by john dai

Hello, I am making a script and I am lost on how to rightclick forever, until an image appears on the screen. Can anybody help me what is it I have to type? Thanks.

Question information

Language:
English Edit question
Status:
Solved
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Solved by:
RaiMan
Solved:
Last query:
Last reply:
Revision history for this message
Best RaiMan (raimund-hocke) said :
#1

while not exists(image):
    rightClick(somewhere)
    wait(1)

Revision history for this message
john dai (acm2lan2) said :
#2

Thanks RaiMan, that solved my question.