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 delete a files ...
Power Automate
Answered

How to delete a files from sharepoint at the end of my flow?

(0) ShareShare
ReportReport
Posted on by 25

Hi,

I have made a flow that pulls email attachements into sharepoint then moves data from the created files into a master file. 

However, when the data is extracted I would like to delete these attachements, so that the sharepoint folder does not get over populated with files.

I am new to using flows so it would be much appreaciated if someone could show me a way to get rid af these files once they have served their purpose 😊

Categories:
I have the same question (0)
  • Verified answer
    Manish Solanki Profile Picture
    15,167 Moderator on at

    Hi @Lasse4 

     

    You can use "Delete file" action to delete the file in SharePoint folder. This action requires the file identifier as input:

    ManishSolanki_1-1695971176724.png

     

    File identifier can be obtained from "Get file properties" action which accepts the Id of the SharePoint file as input:

    ManishSolanki_0-1695971108774.png

     

    Using the combination of those actions you will get the identifier from dynamic content window as shown below & able to delete the file:

    ManishSolanki_2-1695971352925.png

     

    If this helps & solves your problem, please remember to give a 👍 and accept my solution as it will help others in the future.

     

    Thanks

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