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 :
Power Platform Community / Forums / Power Apps / Office365Users.SearchU...
Power Apps
Unanswered

Office365Users.SearchUser - Use column value from Gallery as search text.

(0) ShareShare
ReportReport
Posted on by

Hi,

 

I have a ComboBox1 who's Items property is set to the following;

Choices([@'Share_Point_List_1'].'Name')

This code successfully brings in all the items in column 'Name' from 'Share_Point_List_1'. The column 'Name' is a look up column in SP.

 

I then have a Gallery called 'Gallery_MasterList' who's 'items property is set to the following;

Filter('Share_Point_List_2', 'Name' = ComboBox1.Selected.Value)

So this is filtering Share_Point_List_2 and its column 'Name' with the value selected from the 'ComboBox1' above. The column 'Name' in Share_Point_List_2 is of text format.

Here is what I would like to achieve;

  • Expand the filter above so that it filters on 'Name' column but returns the value of another column called 'SME'. The 'SME' column is of Person type column
  • Take that persons name and use it as search text in Office365Users.SearchUser

I have another Combobox set up with the following parameters;

PAForum2.png

PAForum2.png

So, in 'DefaultSelectedItems' property the name of the SME is passed to it. It would be great if this can be done and appreciate any help.

 

 

Thanks

Categories:
I have the same question (0)
  • gcmfaizan Profile Picture
    1,022 on at
    Re: Office365Users.SearchUser - Use column value from Gallery as search text.

    @Marty3012 ,

    To use the SME's name as search text in Office365Users.SearchUser, you can use the LookUp like:

    Office365Users.SearchUser(LookUp('Share_Point_List_2', 'Name' = ComboBox1.Selected.Value).SME)

    Set the DefaultSelectedItems for ComboBox2 if you want to display the user's display name, it can be set like this:

    Office365Users.SearchUser(LookUp('Share_Point_List_2', 'Name' = ComboBox1.Selected.Value).SME).DisplayName

     

    If this is the answer for your question, please mark the post as Solved.
    If this answer helps you in any way, please give it a like.

     

    Thanks!

  • Marty3012 Profile Picture
    on at
    Re: Office365Users.SearchUser - Use column value from Gallery as search text.

    Hi, thanks for the quick response.

     

    I probably didn't explain my use case properly. Below is an example of how I would like things to go;

    PAForum3.png

    Later on in the form when the user submits, the new SME person will be added. This I can look into later.

    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

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 322 Super User 2025 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 209 Super User 2025 Season 2

Last 30 days Overall leaderboard