Page navigation using sikuli

Asked by Anjali

Helo sir,

I have a presentation slide, i need to traverse the pages(i mean from page 1 to page 20).I want to do it using mouse click after each 10-20 sec.How can i automate that ?

I had given the image of previous/next button image. Can u help me in automating the page navigation using mouse click and image ??

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
RaiMan (raimund-hocke) said :
#1

Supposing that the button find/click works, just put a wait(15) after the click.

Put this in a loop. see faq 1437

Revision history for this message
Anjali (ammasanjali89) said :
#2

Hi,
If i put wait(15) after each click(img). i think my code will contain more than 16 statements like this.
Can it be done using loops ?

I referred ur link faq1437.
for n in range(10): # 10 times, n will be 0 to 9
   pass

But it is navigating tll 3rd slide, after that its getting stop.

Revision history for this message
RaiMan (raimund-hocke) said :
#3

what error/symptom?

Revision history for this message
Anjali (ammasanjali89) said :
#4

No error is displayed, but it is getting stopped after navigating to 3rd page.only page 1 and page 2 it is navigating.

Revision history for this message
RaiMan (raimund-hocke) said :
#5

paste your code

Revision history for this message
Anjali (ammasanjali89) said :
#6

doubleClick("greekmytholo.png")

click("hl.png")
wait (5)
for n in range(10):
   pass

Revision history for this message
Anjali (ammasanjali89) said :
#7

greekmytholo.png it is my ppt file. its getting opened. hl.png is the image for next button.

Revision history for this message
Best RaiMan (raimund-hocke) said :
#8

Uuups, scripting beginner ;-)

doubleClick("greekmytholo.png")
wait(5) # for presentation to get ready

for n in range(10): # do it 10 times
    wait (10) # show 10 seconds
    click("hl.png") # switch to next slide

Revision history for this message
Anjali (ammasanjali89) said :
#9

Hi sir,

Thanks for ur comments. My problem has been solved :-)

Revision history for this message
Anjali (ammasanjali89) said :
#10

Thanks RaiMan, that solved my question.