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 / ComboBox Filter in Off...
Power Apps
Answered

ComboBox Filter in Office365Users

(0) ShareShare
ReportReport
Posted on by 22

Hi All,

 

I am new to PowerApps. I have built a simple data collection app and I would like to rollout a survey through this app. I have a combo box which is linked to office365Users data source. Is there any way i could restrict the combo box to be able to select employees who belong to one particular Country?

 

 

Categories:
I have the same question (0)
  • Verified answer
    shoog Profile Picture
    2,164 on at

    You can set the Items property of your combo box to

    Filter(Office365Users.SearchUserV2().value,Country="YourCountry")
  • indras111 Profile Picture
    22 on at

    Similar to Country, Is there a way to filter employee data for Regular Employees?

  • shoog Profile Picture
    2,164 on at

    If there is a property in your AD that designates "regular employees", you can use that property to filter similar to country.

  • indras111 Profile Picture
    22 on at

    Hi shoog, I really appreciate your prompt response. how do i check all available properties associated with my AD?

  • Verified answer
    shoog Profile Picture
    2,164 on at

    The easiest way would be to create a datatable with Items Office365Users.SearchUserV2().value

    You can then add all fields that could be interesting for you to find out what fields are populated in your AD.

  • indras111 Profile Picture
    22 on at

    Thank you shoog. I was able to do that. Unfortunately, the filed i was looking for not added in that dataset. But now i am able to understand how to find any such data fields. Thank you so much. I have already accepted your primary solution.

  • ziplock77 Profile Picture
    6 on at

    Did anyone else read this in Nancy Gribble's voice?

  • ziplock77 Profile Picture
    6 on at

    Greetings, shoog. Are there field property requirements? Primary Text or SearchField? Does it matter? I've got them set to DisplayName and JobTitle, respectively, but nothing returns.

    I know the connector works and data populates, because I've tried the SearchUser and it will return lists. However, when I use the syntax required for SearchUserV2, I have no such luck. E.g.,

    Filter(Office365Users.SearchUserV2().value,JobTitle="Director")

    TIA for any thoughts on this.

  • subsguts Profile Picture
    1,259 Moderator on at

    This doesn't work if you are using a combobox that allows the user to type in and have name come up.  Today, I use the following:

    Office365Users.SearchUser({searchTerm:cmbRequestor.SearchText})

    However, changing this to V2, doesn't work at all, it gives garbage entries in the combo box and in addition it doesn't let the user type in the box to find the person they are looking for.  Appreciate help on this as if this the original SearchUser goes away, I will need to completely re-program this to use a text box with some type of lookup, which would be a LOT more effort for something that shouldn't be needed.  Why would they get rid of the ability to use a combobox with SearchUser?

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 765 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 272

Last 30 days Overall leaderboard