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 / How to wait for the fi...
Power Automate
Answered

How to wait for the file to be downloaded (always different name of the file)

(0) ShareShare
ReportReport
Posted on by 4

Hi everyone,

 

I'm making a flow where I need to download a file that is often pretty big (sometimes it will take up to few minutes to download).

The name of the file will always be custom but the extension of the file will always be the same.

 

Is there a way to wait for the file to finish downloading and then continue the flow? Wait for the file function won't work because the name is always different. I have tried solutions from this forum but nothing seems to work (I'm pretty sure that I'm doing something wrong). Does anyone have a screenshot with similar solution?

 

I have also thought about checking whether the extension of the file is .mp4 not mp4.part (mp4.part is the extension that shows up when the file is still being downloaded) and waiting until the file with that extension dissapears.

 

Could anyone help me with the solution, I would be very grateful.

Thank you in advance.

 

Solution that I already tried but I can't make it work properly. https://powerusers.microsoft.com/t5/Power-Automate-Desktop/Wait-for-file/td-p/1960845

I have the same question (0)
  • Verified answer
    momlo Profile Picture
    1,527 Super User 2024 Season 1 on at

    Hi @Sim0n242 

    There are couple of ways to achive that.

    Filename is not an issue - In all my flows where i download files, these files have different names, and I have 10s of thousands of those.

    What you can do:

     1. Use automation browser (stripped down version of IE) and dedicated action to download file action, it automates the save as dialog and has built in option to wait for the file, it also gives you the files name as object for you to work with it later.

    2. Automate the save as window manually. Set your desired browser to always ask where to save the file. Go to link/click whatever triggers the file to download. Automate the "save as" window - add wait for the window to appear, then enter filename you want to use for that file, click save. Then just use the same value in wait for the file action.

    3. Configure your browser to always save file to downloads. Before downloading the file get list of files in downloads, download file, get second list of files in downloads, subtract first list from second and you will get new file.

     

    My pref is the second option as this is very reliable once you learn how to do it

     

  • Sim0n242 Profile Picture
    4 on at

    Second solution works great! In my opinion this solution works the best on Google Chrome Canary (I couldn't make it work on Firefox).

     

    Thanks for your help @momlo  🙂

  • kalmer Profile Picture
    2 on at

    Hello!

     

    Just read you comment that "Filename is not an issue - In all my flows where i download files, these files have different names, and I have 10s of thousands of those."

    I'm just having issuses with a desktop flow where i must extract data from PDF. There i must choose a file. I have tried many solutions, but always end up changing the file name before i run the flow or choose a file. My preferd solution would be when i add a file to a specific folder the flow starts.

     

    Please explain how i can resolve this issue!

  • momlo Profile Picture
    1,527 Super User 2024 Season 1 on at

    Hi @kalmer it will be better if you create separate thread where you give more details on what scenario you are automating (i.e. files store on file system, or share point / one drive etc)

  • ammadkhan Profile Picture
    10 on at

    I have used while loop from 1 -- 60 loops.. in this while loop i have used wait for 1 second and then I used the step to get all the files in download folder. --> if the download folder file count is not equal to 0 then i said break the loop.. otherwise it should do while loop 60 times... I hope it will help you. 

    whileloopdownloadwait.PNG
  • SCuellar Profile Picture
    23 on at

    You can use the CreationTime property the file variable has

     

    SCuellar_1-1702612491810.png

     

    1. Read all the files in download folder with desired extension and order files to have the newest file in the element File[0].
    2. Set %OldFileCreationTime% = %File[0].CreationTime%
    3. Loop while %OldFileCreationTime% = %File[0].CreationTime%
    4. Read all the files in download folder with desired extension and order filest to have the newest file in the element File[0].
    5. Show message "Downloading File" during 2 seconds.
  • JimSteinkoetter Profile Picture
    2 on at

    I'm trying to use your second solution to address the same issue as OP.  I'm using Microsoft Edge and used the PAD recorder to record the steps, per your instructions.  For some reason, when the flow doesn't recognize the "Save As" button, even though it recorded the step, "Press button Button 'Save as'"

     

    I've tried recording the steps multiple times, but it always errors out and tells me it can't find the button.  Any thoughts on this?

     

    In the meantime, I'm just adding an unnecessarily long wait time to give my file time to download.  It works, but is inefficient and I'd rather have the flow move on as soon as the file is done downloading.

     

    Appreciate your help!

  • SCuellar Profile Picture
    23 on at

    I disabled the following setting so , "Save As" button is never triggered.

    The file will go directly to your Downloads folder where (from my point of view) is easier to handle than the "Save As" button.

     

    You can disable it with this setting:

    SCuellar_0-1716251027086.png

     

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 557

#2
Valantis Profile Picture

Valantis 328

#3
David_MA Profile Picture

David_MA 264 Super User 2026 Season 1

Last 30 days Overall leaderboard