web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id : v3ZAjyV7+Ni0oNaqX7hc7U
Power Apps - Building Power Apps
Answered

How To: Filtering People Picker

Like (1) ShareShare
ReportReport
Posted on 5 Mar 2019 14:45:56 by 180

Not a question, but a tutorial. I'm not sure if this is the best way but I've seen a few people ask to be able to filter the people picker to a certain department, and I haven't really seen much that works. This is a bit of a MacGuyvered solution, but it works for me at least. There are a few parts to it.

 

I wanted to create an app that would allow management to easily log sick calls from our associates. Our organization has many, many locations nation wide, but I wanted the app to only select people from our office. The sick calls are stored in Sharepoint on a list called "SickCalls", and there is a person feild that I call "Employee." This is how I managed to get the results I wanted.

 

1) Create a list of people you want to appear in the dropdown.
- In my case, I work for an orgnaization with many locations across the country. I wanted only people from my location
- I create a flow that maintains a list of everyone in the location. It starts by adding the director, and then every time someone is added, it adds whoever reports to them. It goes by down the list recusrively until no one is left.
- This runs on a schedule so that it is automatically updated
- For the purposes of this post, I'm calling this list "Org"
- The list has two columns Title, which is copied from the display name and the people feild
2) On the form, create a custom DataCard
3) Create a combobox
- Set the Items property to Sort(Org.Title, Title)
- List should be searchable, and only one person can be selected
- We'll call this ComboBox "Person"
3) Add a default DataCard for the "Employee" column for the "SickCalls"
- Set it to advanced
- Set the "Update" property to the following

{ 
 DisplayName:User().FullName,
 Claims:"i:0#.f|membership|" & Lower(LookUp(Org, Title = Person.Selected.Title , Associate.Email)), 
 Department:"", 
 Email:LookUp(Org, Title = Person.Selected.Title , Associate.Email), 
 JobTitle:"", 
 Picture:""
}

- Set "Visible" to false

 

Its not an elegant soliution by any means, and it may not work for all applications, but I have found it useful.

I have the same question (0)
  • Verified answer
    v-xida-msft Profile Picture
    on 07 Mar 2019 at 03:08:24
    Re: How To: Filtering People Picker

    Hi @RTW ,

    Thanks for your sharing. I would share your solution with my colleagues.

     

    Best regards,

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

MS.Ragavendar – Community Spotlight

We are honored to recognize Ragavendar Swaminatha Subramanian as our September…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 982 Most Valuable Professional

#2
MS.Ragavendar Profile Picture

MS.Ragavendar 396 Super User 2025 Season 2

#3
Power Apps 1919 Profile Picture

Power Apps 1919 356

Last 30 days Overall leaderboard
Loading complete