Take screenshot dynamically on idx value

Hi Guys,

I have a web page with multiple images with each image has different idx value so here I am passing idx value dynamically to take screenshot of that particular image.

Here when I tried to use like that after login the window scrolls down and I am getting saved image in black color. Here when I checked I idx value in message box, i am getting correct value but screenshot is not getting properly.

So can anyone help me out.


Hi, those idx are only internal indexes uipath creates for elements that dont really have good specific selectors, please try to not rely on those for safer automations.

hello @suresh_kumar4

I would approach it like:

  • Get images element by using FindChildren activity with FIND_DESCENDANTS scope.
  • Iterate over these elements and download the image base on the src attribute.

If you just want one image, I’ll use another attribute (like alt or src or its parent) in its selector (you can continue to use idx for the following if you prefer) but then download that image based on it’s src attribute. If base64, convert then save into a file.