Multiple Images Found

Hi ,

I have a web page which contain multiple frames with same images with no text attached . Now , If i search that image it shows me multiple images found for Ex close icon - it gives found 2 times . I can differentiate between these images and perform action on image I require ?

Thanks in Advance
Saurabh Sharma

Hi Saurabh,

Are the images ALWAYS in the same place? If so, you can try finding one unique image, then specifying where to click in relation to that unique image.

To do this, place your capture box around the unique image, then hold the Control (Ctrl) key and click the spot on the window that you want to click. You will see that the red crosshair will move outside of the defined image space.

However, if the images are not ALWAYS in the same location, then this technique will not work. In that case, I will be of no help.

Good luck

Yes, using a hotSpot relative to the location of a unique image is a great technique in many situations. Here’s another way to go about it:

The everyImageLocation() function will give you a list of all of the locations where an image appears on the screen. eggPlant searches the screen from top to bottom (and left to right for images that are at exactly the same distance from the top of the screen).

So for example, to click the second close button, the code would look like this:

put everyImageLocation("closeButton") into closeLocations
click item 2 of closeLocations