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 Apps / Function to remove att...
Power Apps
Answered

Function to remove attachments on Sharepoing

(0) ShareShare
ReportReport
Posted on by 26

Hello all,

 

I am facing the same problem for a few hours and I haven't found any help here on the comunity.

I am using a form to save data on a sharepoint list along with an attachment file regarding a user. I want some function that enables me to remove the attachment file stored in a record without deleting the record itself. I know I can do it through the form but my goal is to do it through a button which will update the filds of name to "dummy" and delete the attachment associated to the record. Using the Patch function I am able to update the fields to "dummy", however I have not find a way to delete the attachment associated to the record...

So far I have figured out that the record.Attachments is a table with four fields: AbsoluteUri, Display Name, Id and Value. If the record doesn't have any attachment this fields are blank. My goal is to delete this attachment from the Sharepoint using some function. Do you have any suggestion?

 

The remove function remove all the data and I just want to update fields (already I have done it) and delete the attachment file.

 

Regards,

Pedro Pereira

Categories:
I have the same question (0)
  • Verified answer
    v-yutliu-msft Profile Picture
    Microsoft Employee on at

    Hi @PedroPereira ,

    Do you want to delete the attachments by clicking a button?
    I'm afraid it's not supported currently in PowerApps.

    For now, you coul only change/add/delete the attachments in the Attchments control.

    I suggest you express your views about adding more ways to manage attachments on PowerApps Ideas Forum. Your precious feedback will be very helpful for our work.

    https://powerusers.microsoft.com/t5/PowerApps-Ideas/idb-p/PowerAppsIdeas

     

     

    Best regards,

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 Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 494

#2
WarrenBelz Profile Picture

WarrenBelz 352 Most Valuable Professional

#3
11manish Profile Picture

11manish 323

Last 30 days Overall leaderboard