sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #40429
Re: [Question #403018]: Pass value from handler (on appear) to main script
Question #403018 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/403018
Status: Open => Answered
masuo proposed the following answer:
My sample codes may help you.
def handler(event):
global count
event.stopObserver()
count = count + 1
msg = "count=%d" % count
popup(msg)
observe(FOREVER, background = True)
onAppear("image.png",handler)
observe(FOREVER, background = True)
count = 0
while count < 10:
popup("Dummy popup")
stopObserver()
--
You received this question notification because your team Sikuli Drivers
is an answer contact for Sikuli.