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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Power Apps Dropdown
Power Apps
Unanswered

Power Apps Dropdown

(0) ShareShare
ReportReport
Posted on by 4

Hello,

 

I created a dropdown object that retrieves the Office 365 users at my company. I entered this code in the Items property to retrieve the domain users:

 

Office365Users.SearchUser({searchTerm:ComboBox1.SearchText,top:1})

 

When I click to expand the dropdown object, it displays two items "AAA Support" and "test." Is there a way to hide the domain user names in the dropdown list but only display the domain user name when there is an exact match?

 

Thanks

Categories:
I have the same question (0)
  • C-Papa Profile Picture
    1,836 on at

    Hi, you should be able to wrap this in a filter to get the value you want something like the below

     

    Filter(Office365Users.SearchUser({searchTerm:ComboBox1.SearchText,top:1}),DisplayName = "AAA")

     

    You can change DisplayName to anything from the link below and string "AAA" can be change or set to a variable.

     

    Connect to Office 365 Users connection from Power Apps - Power Apps | Microsoft Docs

  • GDC Profile Picture
    4 on at

    Thanks for replying. When I add the code you provided to my dropdown 'Items' property, it does remove the "AAA Support." What happens now is when I type an employee's name into the dropdown field, no match value is being returned. The dropdown DisplayField remains blank. Did I enter the code you provided in the correct property? 

  • Verified answer
    C-Papa Profile Picture
    1,836 on at

    Sorry, this should do it, but they will have to type in the full name to get a match. the search in red is testing if ComboBox1.SearchText is anywhere in the user search table (Connect to Office 365 Users connection from Power Apps - Power Apps | Microsoft Docs). The filter part in green is testing that the results from the search in red, the DisplayName is equal to ComboBox1.SearchText.

     

    Filter(Office365Users.SearchUser({searchTerm:ComboBox1.SearchText,top:1}),DisplayName = ComboBox1.SearchText)

     

    If you want the results to change as you type, you could use startswith() instead:

     

    Filter(Office365Users.SearchUser({searchTerm:ComboBox1.SearchText,top:1}),StartsWith(DisplayName, ComboBox1.SearchText))

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard