Skip to main content

Notifications

Community site session details

Community site session details

Session Id : jT19L4EPmQsDxtUyqTgX3V
Power Automate - Power Automate Desktop
Unanswered

UI Element As a Text Variable

Like (0) ShareShare
ReportReport
Posted on 15 Apr 2024 20:49:24 by 77

Hi,

I added a UI element as a text variable.  The result only returns the first match in the  u.i element, how do I get it to return all the matches and not just the first one.  The picture below is the UI element selector, I want everything containing "California" to appear (there are 4 in this case). I realize that I can't use the variable incremental since the variable is a text.  I couldn't get the loop to work either, this is some sort of a drop down list but doesn't have the "select" id in the html.

 

What am I doing wrong or what can I do to get the right result. Thank you

 

GenAi_1-1713213924270.png

 

 

 

 

 

  • Nived_Nambiar Profile Picture
    17,550 Super User 2025 Season 1 on 18 Apr 2024 at 17:23:48
    Re: UI Element As a Text Variable

    Hi @GenAi 

     

    May be show how your main dropdown menu looks like in html structure (select tag simmilar) in your case

    and also how options html structure looks like (option tag simmilar) so that we can design a css selector for this 🙂

     

    Thanks & Regards,

    Nived N 🚀

    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs

    🔍 Found my answer helpful? Please consider marking it as the solution!
    Your appreciation keeps me motivated. Thank you! 🙌

     

  • GenAi Profile Picture
    77 on 17 Apr 2024 at 20:24:40
    Re: UI Element As a Text Variable

    Hi,

     

    Thank you for all your help. I know how to write the css selector when the html contains the "select" function (your example contains the select function), but the html I am working with doesn't have the select function but rather the button function. I tried replacing the "select" with button in the css but didn't work. 

  • Nived_Nambiar Profile Picture
    17,550 Super User 2025 Season 1 on 17 Apr 2024 at 18:16:09
    Re: UI Element As a Text Variable

    Hi @GenAi 

     

    Let me share a simple example for this 

     

    assume this is the dropdown values u need to capture

    Nived_Nambiar_0-1713377443218.png

     

    Now see its html structure

    Nived_Nambiar_0-1713377505950.png

     

    Using extract data from webpage action > i have written this css selector 

    Nived_Nambiar_1-1713377678835.png

     

    as u see i get all dropdown values as output. Well you can still filter it up utilizing the regex options as well.

     

    Hope this idea helps !

    Thanks & Regards,

    Nived N 🚀

    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs

    🔍 Found my answer helpful? Please consider marking it as the solution!
    Your appreciation keeps me motivated. Thank you! 🙌

     

  • Nived_Nambiar Profile Picture
    17,550 Super User 2025 Season 1 on 17 Apr 2024 at 18:16:06
    Re: UI Element As a Text Variable

    Hi @GenAi 

     

    Let me share a simple example for this 

     

    assume this is the dropdown values u need to capture

    Nived_Nambiar_0-1713377443218.png

     

    Now see its html structure

    Nived_Nambiar_0-1713377505950.png

     

    Using extract data from webpage action > i have written this css selector 

    Nived_Nambiar_1-1713377678835.png

     

    as u see i get all dropdown values as output. Well you can still filter it up utilizing the regex options as well.

     

    Hope this idea helps !

    Thanks & Regards,

    Nived N 🚀

    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs

    🔍 Found my answer helpful? Please consider marking it as the solution!
    Your appreciation keeps me motivated. Thank you! 🙌

     

  • GenAi Profile Picture
    77 on 17 Apr 2024 at 15:19:01
    Re: UI Element As a Text Variable

    Yes

  • Nived_Nambiar Profile Picture
    17,550 Super User 2025 Season 1 on 17 Apr 2024 at 02:25:29
    Re: UI Element As a Text Variable

    Hi @GenAi 

     

    is it like you are trying to capture all dropdown values having word CALIFORNIA ?

     

    Thanks & Regards,

    Nived N 🚀

    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs

    🔍 Found my answer helpful? Please consider marking it as the solution!
    Your appreciation keeps me motivated. Thank you! 🙌

     

  • GenAi Profile Picture
    77 on 16 Apr 2024 at 18:55:48
    Re: UI Element As a Text Variable

    I tried that initially but didn't work for me. 

  • GenAi Profile Picture
    77 on 16 Apr 2024 at 18:53:28
    Re: UI Element As a Text Variable

    This is what I got from the inspect, each account is unique but they all start with California. Below the first image is another inspect just for one of the element of the drop down. Thank you

     

    GenAi_0-1713292847093.png

    GenAi_1-1713293366930.png

     

  • Nived_Nambiar Profile Picture
    17,550 Super User 2025 Season 1 on 16 Apr 2024 at 18:25:17
    Re: UI Element As a Text Variable

    Hi @GenAi 

     

    could you select element and use inspect element option so to see html structure of it ?

    Thanks & Regards,

    Nived N 🚀

    LinkedIn: Nived N's LinkedIn
    YouTube: Nived N's YouTube Channel
    Blog: Nived Nambiar's Blogs

    🔍 Found my answer helpful? Please consider marking it as the solution!
    Your appreciation keeps me motivated. Thank you! 🙌

     

  • GenAi Profile Picture
    77 on 16 Apr 2024 at 18:23:56
    Re: UI Element As a Text Variable

    I was only able to extract the first element that contained "California"

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Warren Belz – Community Spotlight

We are honored to recognize Warren Belz as our May 2025 Community…

Congratulations to the April Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard > Power Automate - Power Automate Desktop

#1
eetuRobo Profile Picture

eetuRobo 4 Super User 2025 Season 1

#2
KO-05050229-0 Profile Picture

KO-05050229-0 2

#2
stampcoin Profile Picture

stampcoin 2

Overall leaderboard