web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / click - extract - clos...
Power Automate
Unanswered

click - extract - close - next - repeat

(0) ShareShare
ReportReport
Posted on by 4

How to: 

  1. Click on an element on a webpage (a pop-up comes up)
  2. extract all the data on that pop-up
  3. add to excel sheet
  4. close pop-up
  5. go to the next element and repeats steps 1,2,3,4,5
  6. and do that for 3000ish elements on a web page 

 

If anyone may pls redirect me to a tutorial or straight up tell me how, you would be greatly appreciated.

 

Thank you

~Bozhidar

I have the same question (0)
  • NikosMoutzou Profile Picture
    Microsoft Employee on at

    Hello @Bozhidar743 !

     

    I consider that your use case could be handled with the use of a loop (and incremental variable) adn the creation of a dynamic selector for the elements you would like to click on. The incremental variable should be used in the selector of the element and with each execution, the 'new' selector would define the next element.

     

    In order to proceed with this approach, you should check the selectors of the elements and find where the variable should be used.

     

    Some related documentation:

    UI elements and controls - Power Automate | Microsoft Docs

    Build a custom selector - Power Automate | Microsoft Docs

  • Bozhidar743 Profile Picture
    4 on at

    Hey @NikosMoutzou 

    I'm still a little confused on how to get step 4 to have a different UI element (button) with each loop.

    I extracted all the elements I want to be clicked in the variable "DataFromWebPage".
    Is there a way i can get Power Automate to cycle through the elements from "DataFromWebPage" and then continue with the steps and repeat?

    or may you pls explain a dynamic selector pls 🙏
    power Automate pic 1.png

  • NikosMoutzou Profile Picture
    Microsoft Employee on at

    Hello @Bozhidar743 .

     

    Dynamic selector is a selector defined inside a desktop flow, which is intended to interact with a specific UI element, even if the selector of the UI element might change between flow executions.

    For that purpose, Power Automate Desktop offers the capability to the user to use operators inside the Selector builder, for making dynamic the value that a attribute of the selector can take. More information can be found here: Build a custom selector - Power Automate | Microsoft Docs

    For your case though, you probably have to create a loop with variable that would take incremental values. I suspect the selector for the UI elements you would like to interact with would be of the format:

    First UI element: html > body > div > table > tbody > tr:eq(0) > td:eq(0)

    Second UI element: html > body > div > table > tbody > tr:eq(1) > td:eq(0)

    Third UI element: html > body > div > table > tbody > tr:eq(2) > td:eq(0)

    As you may observe, the 'tr:eq(x)' is dynamic, it changes for each element while the rest of the selector remains the same. Therefore, you have to replace the number inside with a variable (lets say 'x') that would start from 0 and goes up to the number of elements-1. The selector defined inside the 'Extract data from web' action should be something like:  html > body > div > table > tbody > tr:eq(%x%) > td:eq(0).

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Valantis Profile Picture

Valantis 474

#2
11manish Profile Picture

11manish 268

#3
David_MA Profile Picture

David_MA 243 Super User 2026 Season 1

Last 30 days Overall leaderboard