cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
PowerAGuy
Helper III
Helper III

Prevent approver from deleting attachments added by another user

Hey all,

I think this sort of works but want to know if I can enhance the user experience or if indeed there is a better way:

 

  • I have a user (user1) completing Part 1 and I'm using the attachment control for them to upload 1 or more files.
  • Reviewer (user2) then has the same attachment control (as I can only use 1 attachment control per record, without doing anything like adding another data source to store this) to further upload an attachment or more.

I need to prevent user2 from removing what user1 added to SP, but also want user2 to upload at least 1 attachment before they can submit the review, I have this on the OnRemoveFile property of the attachment control:

 

Reset(Self);
Notify("You cannont delete attachments files")

 

It seems to sort of work, if User2 attempts to remove User1s attachment it displays the above message and does not allow deletion, and if accidently User2 adds an attachment and wants to remove it, he/she can BUT it still presents with the notification and deletes their own attachment.

Can I firstly make user2 add at least 1 attachment (I presume a count formula of some sort will be required on the existing record, any help if this is the best way please)?
Secondly allow user2 to remove any attachments they added (prior to saving), but not see the notification?

 

Thank You

0 REPLIES 0

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (3,425)