Notifications
Announcements
Hi PowerApps community
I have a question about restricting access to one of my buttons.
Employees can access button "Formulier IDEWA" (see picture 1). There they can fill in a form that will be saved in button "Lijst IDEWA's". However I want to restrict access to button "Lijst IDEWA's" for employees so that only managers (people who are site owners on Sharepoint - see picture 2) can click on button "Lijst IDEWA's".
How can this be done?
Picture 1
Picture 2
Hi @Bensen ,
I would say it's better and easier that using a list to manage site owners including their Names and Emails, otherwise you will have to create a custom connector using Graph Api or trigger a flow to get owner members. Please check below thread:
Solved: Get SharePoint Group Membership in App to use for ... - Power Platform Community (microsoft.com)
With the help of an Owners list, you can use it as data source, checking logged in users and if their Email is in that list, enable or show that button, else disable or hide it from the screen.
Best regards,
Create a two-item SharePoint list with just one column. Name one item Owners and the other Members. Set up access permissions for each item so that only members are able to see the Members item, and only owners can see the Owners item. Then do a LookUp(), or a filtered CountRows() on app start via the OnStart property to set the permissions of a variable. Then you can hid or disable controls all over the app based on this variable. This is how I do it in all of my apps, and it works great. To check for a visitor, do an unfiltered CountRows(). If the result is 0, you know the user is a site visitor.
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.
In our never-ending quest to improve we are simplifying the forum hierarchy…
We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
WarrenBelz 721 Most Valuable Professional
Michael E. Gernaey 320 Super User 2025 Season 2
Power Platform 1919 268