← Back to team overview

sikuli-driver team mailing list archive

[Question #403973]: Problem if Exists(Image)

 

New question #403973 on Sikuli:
https://answers.launchpad.net/sikuli/+question/403973

Hi again, I've some trouble with this :

def Search():
    if exists(image):
        for x in findAll(image):
            click(x)

[error] FindFailed ( can not find P(xxxxxx.png)


I've understood that if there are no images to find, it fails, but how can I do then ?

(I want to click on all images corresponding but if there are no images, don't do anything at all and continue my script)

Thanks again, quick and precise :)

-- 
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.