← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #678932]: Repeat

 

Question #678932 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/678932

Rainer proposed the following answer:
Your code should look like this:

for i in range(200):
      click(1006,748)
      click("1551707620478.png")
      type(Key.ENTER)
      type('c', KeyModifier.CTRL)
      click("1551704040161.png")
      type('v', KeyModifier.CTRL)
      sleep (2)
      if(exists("1551704943136.png")):
          click(613,587)
          type('a', KeyModifier.CTRL)
          type(Key.DELETE)
          click("1551707221495.png")
      else:
         click("1551703683676.png")
         find("1551706524071.png")
         click("1551706538103.png")


The whole code in the "for" block (everything that you want to be executed repeatedly) needs to be indented (moved to the right) by one level.

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