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 / Filtering dropdown lis...
Power Apps
Answered

Filtering dropdown list based on whether user has a 1 against certain columns in the data source (sharepoint list)

(1) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi All, 

Let me start off by saying I am completely new to Power Apps so I am not sure if what I am trying to do is difficult or simple. 


I have a Sharepoint list called Security that looks like this:

EmailAfricaEuropeNorth AmericaMENA
allison@company.com1   
bob@company.com 11 
tim@company.com  1 


Requirement:
I want to have a drop down list with the regions specified in the columns: Africa, Europe, North America and MENA.
If the logged in user's email exists in the "Email" column and they have a 1 against a specific region, then I dont want the dropdown list to show them the option of selecting that region.

For example, 
If I am Bob and go into the Powerapp, when I click on the dropdown list, I should only see "Africa" and MENA"
If I am Allison, I should only see "Europe", "North America" and "MENA" in the list.

Appreciate any help. 

Categories:
  • BideyYusuf Profile Picture
    387 on at

    Hi @Anonymous Add the table as a connector, then On the Items property of the ComboBox, Put 

    Filter(Security,Email <> User().Email && (Africa = Blank()||Europe = Blank() ||North America = Blank() ||Mena = Blank()))

     

    Its possible you run into a delegation warning with this. but it depends on your scenario.

    Check it, if this works for you.

     

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @BideyYusuf ,
    I tried your solution but I just see blanks in the combo box. I should be seeing Africa as the field is blank in the "Africa" column in my data source against my email.
    How does the combo box know to return the field names e.g. Africa, Europe when they are only referred to in the columns? 

    malireza_0-1669190474140.png

     

  • Verified answer
    SagarVIS96 Profile Picture
    212 on at

    Hii @Anonymous ,

    I based on your requirement what you can do is, create one local collection which transform your columns into rows so that you can get category wise value.
    Sample to create collection is:

     

    Clear(filteredSecurity);
    ForAll(
     Security As s,
     ForAll(
     options As OP,
     Collect(filteredSecurity,
     {
     Name:s.Email,
     Category:OP.Name,
     Value:Switch(
     OP.Name,
     "Africa",
     LookUp(Security,Email=s.Email).Africa,
     "MENA",
     LookUp(Security,Email=s.Email).MENA,
     "NorthAmerica",
     LookUp(Security,Email=s.Email).NorthAmerica,
     "Europe",
     LookUp(Security,Email=s.Email).Europe
     )
     })
     )
    )

     

    After creating this collection use this collection as an item in the dropdown with some filter:
    Example:

     

    Filter(filteredSecurity,Name=User().Email,Value<>1)

     

     

    And then you will see only those countries which don't have value as 1 for the current logged in user.

     

    If you find this helpful, please accept the solution,

     

    Thanks.

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 221 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 188 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 120

Last 30 days Overall leaderboard