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 / Please tell me how to ...
Power Automate
Answered

Please tell me how to reliably control the file selection dialog in a browser.

(1) ShareShare
ReportReport
Posted on by 24
Hello,

I have a question about controlling the dialog that appears when selecting a local file in the Edge or Chrome browser.

Depending on the state of the desktop, I can't control it well, so if anyone knows a more reliable method than mine, I would appreciate your guidance.

I always use the "UI Automation" action to control the dialog. I wait for the dialog to appear, enter the full path of the specified file in the file name, and press the open (or save) button.
In the Edge browser, I prepare UI elements with selectors like the following:
 
> window[Class="#32770"][Process="msedge"]

> window[Class="#32770"][Process="msedge"] > combobox[Class="ComboBox"][Name="ファイル名(N):"] > edit[Class="Edit"]
 
> window[Class="#32770"][Process="msedge"] > button[Class="Button"][Name="開く(O)"]

Basically, there is no problem, but I can't retrieve it when multiple Edge browsers are running on the screen.
Avoiding that situation solves the problem, but sometimes I want to display multiple windows to do some work. Is there a good method for this?
I have the same question (0)
  • Verified answer
    SaiRT14 Profile Picture
    1,992 Super User 2025 Season 1 on at
    pls try the following:
     
    Add more attributes to the selector for better specificity: window[Class="#32770"][Process="msedge"][Title="Open"]
     
    Before triggering the file dialog, capture the title of the parent browser window. Adjust your selector to target dialogs owned by the window with the captured title window[Class="#32770"][Process="msedge"][OwnerTitle="ParentBrowserWindowTitle"]
     
     
  • samoedo Profile Picture
    24 on at
    Thank you for your response.
    (I couldn't figure out how to reply, so I'm replying to myself.)

    Since selectors like Title and OwnerTitle were not available as options in Power Automate Desktop, I adjusted the parent selector to also check the Name attribute based on your advice.

    :desktop > window[Name="Page Title"][Process="msedge"]

    By specifying the page that has the "Open" dialog, it works well even if multiple browsers are open. Making the Page Title part a variable and inserting the title obtained with the "Get details of web page" action allows for dynamic handling, which is very convenient.

    Thank you for the advice.
  • Hairy_Drumroll Profile Picture
    251 on at
    Yes, the key is adjust the 'parent' selector.
    I had to set mine as 
    :desktop > window[Name^="%MyPageTitle%"][Process="msedge"]
    This ensured that the trailling text such as " - Microsoft Edge" didn't stuff it up.

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 Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 252 Super User 2026 Season 1

#2
11manish Profile Picture

11manish 169

#3
Haque Profile Picture

Haque 154

Last 30 days Overall leaderboard