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 / "Save File As" failed ...
Power Automate
Unanswered

"Save File As" failed when plural Chrome running

(0) ShareShare
ReportReport
Posted on by 8

I made a following PAD flow :

  Press button on web page (to download a file, Browser automation)

  Populate text field in window (full path of save file, "save file as" dialog, UI automation)

I'm starting the flow by launching new Chrome instance, and all actions worked well.

I succeeded in saveing the downloaded file.

 

But, if some other Chrome instance (A) exists before runnig the flow, "Populate text field in window" action fails.

The Chrome window (A) activated and PAD fails to find the text field.

How can I fix this probrem?

 

Power Automate Desktopで、Web上のダウンロードボタンを押し、ファイルを保存するフローを作りました。

ファイル保存ダイアログ上の操作には、UIオートメーションを使い、

保存するファイルのフルパスを指定したり、保存ボタンを押したりしています。

Chromeのウィンドウがひとつも無い状態でフローを実行すると、何の問題もなく成功しますが、

先にChromeが動いている状態でフローを実行すると、

ファイル保存ダイアログでファイル名を指定するタイミングで、先に起動していたChromeが前面に表示されてしまい、

PADはファイル保存ダイアログ上のUI要素を見つけられなくなるので、エラーになってしまいます。

エラーは「テキストボックスに書き込めません。(テキストボックスが見つかりません)」です。

フローで作成したChromeインスタンスか、ファイル保存ダイアログを前面に持ってくるなどして、

うまく動作するようにすることはできないでしょうか?

或いは他の解決法があるでしょうか?

  • VJR Profile Picture
    7,635 on at

    Just before populating the text, Attach to the right Chrome window using any of the options in the "Attach to Chrome tab".

     

    VJR_0-1653274477322.png

     

  • Masanori Profile Picture
    8 on at

    Thank you very much for your kind instruction.

    "Launch new Chrome" action succeeded in a paticular way.

     

    Failed flow:

    (a Chrome instance running (A))

    1. Launch new Chrome instance (B)

    2. Click link on web page (download button on B)

    3. Launch new Chrome - Attach to running instance B

    4. Populate text field in window (B) <- one second after this action begins, chrome window A came to the front.

     

    Succeeded flow:

    (a Chrome instance running (A))

    1. Launch new Chrome instance (B)

    2. Click link on web page (download button on B)

    3. Launch new Chrome - Attach to running instance A (differ from the failed flow)

    4. Launch new Chrome - Attach to running instance B

    5. Populate text field in window (B)

     

    Titles (URLs) in the Chrome A is varying, so I can't choose the above idea.

    And the web page with the download button not always in the Chrome A.

    Is there any good solutions?

  • VJR Profile Picture
    7,635 on at

    The "Launch Chrome" has 3 options i. Title, ii. URL and iii Foreground window.

    Are you saying it is not possible to attach using any of the 3 options?

     

    Also remember, the Title OR the URL, both can also take portion of it

     

    VJR_0-1653361956398.png

     

  • Masanori Profile Picture
    8 on at

    > Are you saying it is not possible to attach using any of the 3 options?

    Yes, I am.

     

    > 3. Launch new Chrome - Attach to running instance B

    > 4. Populate text field in window (B) <- one second after this action begins, chrome window A came to the front.

    When I use option i. Title or ii. URL, while action 3 is running, Chrome B is in the front.

    And during action 4, Chrome A comes to the front.

    So actoin 4 fails. Error message : Failed to write in textbox (textbox wasn't found

    When I use option iii Foreground window, action 3 fails.

    Error message : Failed to assume control of Chrome (communication with browser failed. Make sure add-on is installed).

     

    > Also remember, the Title OR the URL, both can also take portion of it

    Thank you, I'm aware about that.

     

    Fro example, Chrome A has following two tabs:

    https://a1.com/*

    https://a2.com/*  

    and Chrome B has one tab:

    https://b1.com/* (a web site for download files)

     

    Bun on another day, Chrome A might have following tabs:

    https://a3.com/*

    https://a4.com/*  

     

    So I can't use the following idea:

    > 3. Launch new Chrome - Attach to running instance A (using option i. Title or ii. URL)

    > 4. Launch new Chrome - Attach to running instance B (using option i. Title or ii. URL)

    > 5. Populate text field in window (B)

  • VJR Profile Picture
    7,635 on at

     

    VJR_0-1653448072388.png

     

     

    You are trying to explain very well using A and B. It is me who is not able to fully understand 🙂

     

    In the beginning, can you get the title and url of the browser instance, save it and use it later to attach when required to the right window?

     

  • Masanori Profile Picture
    8 on at

    Thank you for your polite explanation.

    I was not clear. Chrome A was launched by someone (not PAD) and has been running for weeks.

    So I'm not sure how to make some suitable variables for the argument "web browser instance",

    I think using "custom selector" of PAD might be a solution.

     

    Or, if only I could add a new tab to the Chrome A (also need an argument "web browser instance"),

    "populate text field in window" action will work fine.

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

Leaderboard > Power Automate

#1
Mohsin Ali Profile Picture

Mohsin Ali 389

#2
11manish Profile Picture

11manish 345 Super User 2026 Season 2

#3
M Bilal Khan Profile Picture

M Bilal Khan 308

Last 30 days Overall leaderboard