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 / Office 365 Filter & Se...
Power Apps
Unanswered

Office 365 Filter & Search box with IF Statements

(0) ShareShare
ReportReport
Posted on by 2

Hi,

 

I've created a User Directory which pulls their location from a SharePoint list with a People column linked to O365 to match the user up with their photo. I'd like to link the Gallery to a Search and a Filter, I've written the following... but I get a Boolean error on the below code... 

 

Filter(
AddColumns(
'People Locations',
"UserPhoto",
If(
// check if the the user has an email and a profile picture
!IsBlank(FullName.Email)
And Office365Users.UserPhotoMetadata(FullName.Email).HasPhoto,
// get the profile picture
Office365Users.UserPhotoV2(FullName.Email)
)
),
Office365Users.SearchUser(
{
searchTerm: Trim(TextInput2.Text),
top: 999
}
),!IsBlank(City))

Categories:
I have the same question (0)
  • v-bofeng-msft Profile Picture
    Microsoft Employee on at

    Hi @dazroo ,

    The place I marked in red is redundant in the formula, and deleting it the error will disappear.

    vbofengmsft_0-1678242556890.png

     

    Best Regards,

    Bof

     

     

  • dazroo Profile Picture
    2 on at

    Hi @v-bofeng-msft ,

     

    Thank you for your reply, that solves the error but doesn't help in what I am trying to achieve. Removing the code complete removes the link to the search box I am trying to get working.

     

    I need the search box to find the users or search by location from the SharePoint list 'People Locations' and show the results complete with the users picture pulled from the users O365 profile.

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

Congratulations to the June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 325 Most Valuable Professional

#2
11manish Profile Picture

11manish 165

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 88 Super User 2026 Season 1

Last 30 days Overall leaderboard