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

Restricting the editing and deleting of items



I'm currently building an app that manages inventory within a lab and there is a need to restrict who can edit and delete items to the person who is listed as responsible, their line manager and people who are 'super users'.


To control who can edit and delete, I would like base it off of the following depending on who is logged in to the app. I know this won't affect people's ability to go into the sharepoint list and edit but that's not really a concern. I have the following 2 fields in place that are people pickers:


1. 'Person Responsible'

2. 'Line Manager'

There is also then a seperate list that contains people who are super users and that is connected to the app too.


Effectively, I'm trying to make it so that the 2 buttons below don't appear to anyone for the item unless they are listed as the person responsible or line manager within the item, or they are on the super user list.




What would be the best way to go about this?

Super User
Super User


Assuming that you are getting to this page from a Gallery and that in that Gallery you are setting some sort of variable to be used for your form screen, then you can utilize the following for the DisplayMode property of those icons.



    If(Lower(yourRecordVariable.'Person Responsible'.Email) = _user ||
       Lower(yourRecordVariable.'LineManager'.Email) = _user,



You only need this in one of the icon DeisplayMode properties and then the other can reference that one.  Example, you put this in the Edit icon DisplayMode, then you can set the DisplayMode property of the Delete icon to yourEditIcon.DisplayMode


I hope this is helpful for you.

Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!


Thanks for the help.


I am navigating to this screen from a Gallery, but what do you mean by variable for the form screen? Just to put it into context.

Helpful resources

Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (4,411)