Showing results for 
Search instead for 
Did you mean: 
Regular Visitor

How to use OnRemoveFile of attachments?, I don't want to permit user to delete attachments

Hello, Basically I have an App, then I don't want to permit users to delete files attachments, because the users only have to add files, I need help, I don't know how to use attachment controls for this, somebody can help me?

Community Support
Community Support

Hi @MagiverFlow,

Do you not want the users to delete the files attachments from the Attachments control when the user edit a record?

Based on the needs that you mentioned, I think the Reset function could achieve your needs.

I have made a test on my side, please take a try with the following workaround:8.JPG

Set the OnRemoveFile property of the Attachments control within your Edit form to following:

Reset(DataCardValue9);  /* <-- DataCardValue9 represents the Attachments control within your Edit form */
Notify("You have no permisson to delete the attachment files", NotificationType.Warning)

Please check the attached GIF screenshot for more details:


Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Carousel_PP_768x460_Wave2 (1).png

2022 Release Wave 2 Plan

Power Platform release plan for the 2022 release wave 2 describes all new features releasing from October 2022 through March 2023.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Top Solution Authors
Users online (5,211)