Have a problem deleting a file previously created in SharePoint with Flow.
It is a delete file when item created flow; as i am using a tasklist, when a new item is created i used a different flow to create files (actually wanted just the folders but this is a good work-around) and the thing is that i want those files deleted automatically so just the folders remain. The thing is that flow does not seem to find the file. It is the only file in the library. Please prompt me for more details if you think you may have an explanation or a solution.
If I understand you correctly, you are trying to create a flow to delete a file in SharePoint library when a new item is created in list. Looks like below:
But it seems that the action “delete file” only allows us to select a certain file from the library, if you want to delete several files, it might be impossible.
If I understand you correctly, please consider to create a feature request on Flow Ideas Forum at here:
If I misunderstand you, please feel free correct me and please provide more details about your scenario for better understanding.
Thank you for the reply.
One file is indeed what i want to delete. THe problem is, that is do not have a fixed adress for the file. I need to use dynamic content in the adress. Like so:
The file in question is a .txt file that is created automatically by another flow on the creation of the same item in my tasklist.
The problem is: it finds the lybrary using dynamic content, (or so the error log explains ) but it cant find the txt in the lybrary.
I tried using the following file name paramaters: .txt , dynamic values for ID, NameTag, Task Name (the same used for the adress) even all of the above with .txt at the end. Is it that it can;t find the lybrary because of dynamic content or it doesan't recocnise the file name given trough dynamic content, just a specific name?
If needed i can explain and ilustrate the whole process and folder/lybrary structure i need. Thank you.
Does any one have tried creating a flow to delete a file from SharePoint where in created date/modified date is greated than 3 mos/specified date?
I am trying to look for the trigger for SharePoint to delete a file but not available.
Is there a way or work around to do this?
Have you found a solution for this? I too, am having this problem. I created the delete file step and inserted the site address. In the File identifier field, I am able to find the file that I want to delete in the search box and it deletes the file but, if I type that same information in the box manually, it doesn't work; with or without inserting dynamic content. I cannot hard code a file deletion because I will not know the name of the file that is being uploaded.
Not sure if this helps, but I ran into this problem as well. I tried building the URL dymanically too (as I was using dynaically created folders), but it turns out we don't need to!
-Leave the Site Address as is. My Site URL is blurred out but looks like https://tenantName.SharePoint.com/sites/siteCollectionName
-Use "ID" as the File Identifyer. Make sure to use the ID field from the newly created document.
We've updated and improved the layout and uploading format of the Power Automate Cookbook!
Fill out a quick form to claim your user group badge now!
We've given our badges an overhaul and also added some brand new ones!
Learn how to build the business apps that you need.
Find out where you can attend!
Watch & learn from the Power Automate Community Video Gallery!