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 / Field Specific Securit...
Power Apps
Answered

Field Specific Security Using Sharepoint List

(0) ShareShare
ReportReport
Posted on by 20

I am very new to power apps. My knowledge consists of watching a multitude youtube videos.

General Problem:

I have 2 groups of users (recruiters and administration). The recruiters fill out half the fields on a sharepoint list but view all of the fields. Administration fills out the other half and views all fields. I have the main sharepoint list and a separate lookup list of person roles.

I have built the power apps forms. I need to limit the editability of half the fields from the recruiters. Since sharepoint doesn’t allow column specific security I thought I would try making each field that shouldn’t be edited by the recruiters to be displaymode.view only.

My solution so far:

I am trying to base this off of the sharepoint person role list. Basically, trying to check the list to see if the user name/email is associated with an administration role. If it is an Administration role then displaymode.edit, else displaymode.view. I could then paste this into each field they shouldn’t have access to edit.

I can’t seem to get it to work. Can someone check my if statement and see what I’m doing wrong? To be honest I’m not sure if this approach will even work. Any suggestions are welcome.

Formula:

DisplayMode = If(lookup(‘lkuppersonrole’, user().email = !is blank), if(lookup(‘lkuppersonrole’, role.value= "Administration"), displaymode.edit,), displaymode.view)

 

Hopefully I’m making sense.

Categories:
  • WarrenBelz Profile Picture
    156,963 Most Valuable Professional on at

    Hi @Nick555 ,

    Try this

    If(
     LookUp(
     ‘lkuppersonrole’, 
     YourPersonField.DisplayName = User().Email
     ).Role.Value = "Administration", 
     DisplayMode.Edit,
     DisplayMode.View
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

  • Nick555 Profile Picture
    20 on at

    I tried this but it doesn't seem to be working. I've been monkeying with it but can't seem to get it to work. Both fields are single line text so I'm not sure why it says they are incompatible.

    Nick555_1-1681752913990.png

     

  • WarrenBelz Profile Picture
    156,963 Most Valuable Professional on at

    @Nick555 ,

    The structure is valid assuming Title contains the user's email and Role is a Choice or a Lookup field (I got this from your posted code). If it is Text, just use Role, not Role.Value

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

  • Nick555 Profile Picture
    20 on at

    You are correct, I futzed with the structure it changed the fields to text to try and make it work. Very much appreciated that you sent the correct code for the text version.

     

    It now accepts the formula and I am not getting any red x’s but it doesn’t seem to work security wise. It is making the field  read only now for everyone. Thoughts?

    Nick555_0-1681944367725.png

     

  • WarrenBelz Profile Picture
    156,963 Most Valuable Professional on at

    @Nick555 ,

    Put this on a Label and see what it returns

    LookUp(
     LkUpRecruiter, 
     Title = User().Email
    ).Role

     

  • Nick555 Profile Picture
    20 on at

    Doesn't seem to return anything.

    Nick555_0-1681947920051.png

     

  • Verified answer
    WarrenBelz Profile Picture
    156,963 Most Valuable Professional on at

    @Nick555 ,

    Then there is your problem - you need to compare the field with the user's email in it with the current user.

  • Nick555 Profile Picture
    20 on at
    With your help I figured it out!!! Very much appreciated. I re-did the email column in the list from scratch and things fell into place!

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

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 224 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 189 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 126

Last 30 days Overall leaderboard