Differentiating among identical icons and iterating among those icons

Asked by Narasimha Nithesh Thota on 2017-06-08

Hi

I have a use case where I have to differentiate among 'n' number of identical icons which are separated with equal spaces vertically and they are the child nodes from a parent node. So by differentiating I mean,
1. I should be able to go to 'Icon1' and then perform an activity on on the Icon which directs me to some other page..
2.if I dont find my requirement in the redirected page ,then come back to the page of icons, get to the 'Icon2' which is right below Icon1, and perform the first step and so on..
3.At any point of time if my requirement is met in the redirected page, I have to close the application.

The challenges I am seeing are:
* The Icons are identical, so sikuli is stuck in a loop ending up in taking action on the same icon repeatedly
*The n number of icons can vary and there is no proper pattern where we can make out that at a particular icon the success(The requirements meeting in redirected page) is seen.

Questions I have in mind to implement this scenario:
*Can we get the count of the number of identical icons and then iterate among these icons to get?
* Can I get the space(number of pixels) between successive icons (or) space between the first icon and the last icon?

Please tell me how I can implement this particular scenario with sikuli r930

Question information

Language:
English Edit question
Status:
Answered
For:
Sikuli Edit question
Assignee:
No assignee Edit question
Last query:
2017-06-08
Last reply:
2017-06-09

The Icons are identical when you see but, the data i get after them on the redirected page is different. I have mentioned Icon1 and Icon2 for understanding.

RaiMan (raimund-hocke) said : #2

1. upgrade to version 1.1.1 (http://sikulix.com)

2. have a look at findAll() - should help in your situation

Can you help with this problem?

Provide an answer of your own, or ask Narasimha Nithesh Thota for more information if necessary.

To post a message you must log in.