I created a flow which reads a script to convert the data in an excel file into a table, and it works fine when I use my test file, but the issue I now have is that I will be downloading a report daily and the flow doesn't recognise the new file when it is saved in the same folder as the test file, (I would like to note that the report will be named the same as the test one, this is how the report is named when it is downloaded - there maybe a variation such as Report(1).xlsx, Report(2).xlsx, but if I get Power Automate to delete the f
The report will be saved in a Sharepoint folder, but I was wondering if there is a way to create a flow that is triggered when a new file is added to the Sharepoint folder, and not having to select a specific file when building the flow.
There might be a possibility that the report could be sent daily, but currently, we will be using RPA to download the report daily.
In your Run script action, can you try putting the following expression for your File. that should give you the full path (including file name) of the file that was just created or modified.
outputs('When_a_file_is_created_or_modified_(properties_only)')?['{FullPath}']
@grantjenkins Thank you for this, this is what I was looking for for the first part of the flow, but the issue I now have is if I add the next step, which is 'Run Script' it asks me for a file still:
I tested it out using the same file name, but it says that it cannot find the workbook, when I add a new file in the folder. I think this is because when I initially set it up, I used the spreadsheet that was already saved in the Sharepoint folder, but as I said, there will be a new report that will be saved in the same location daily, and will be named the same as the test one.
Is there a way to run the script without having to select a specific file?
The end result of all of this is to use power automate to send an email to all the named people in the report (email addresses are found in one of the columns).
If the downloaded report is sometimes having the same name (overwriting the previous file) then you will need to cater for both new files and modified files. In this instance I would use the following trigger.
Can you try this and confirm that it now works as expected?
Michael E. Gernaey
497
Super User 2025 Season 2
David_MA
436
Super User 2025 Season 2
Riyaz_riz11
244
Super User 2025 Season 2