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 / Multiple Search filter...
Power Apps
Unanswered

Multiple Search filter boxes for the same sharepoint gallery

(1) ShareShare
ReportReport
Posted on by

Hi All,

 

I am trying to have a gallery that can be filtered by 2 seperate "search" boxes. The gallery is utalising sharepoint as a data source, so I have some deligation issues to work around.

 

This is what I am trying to do currenty with no luck: 

Filter( Projects_1, StartsWith( project_name, TextInput1.Text ), StartsWith(pm_name,TextInput1_2.Text))

 

I also tried what was in the learning material similar to this statment, which also did NOT work:

Filter( Customers, StartsWith( Name, SearchInput.Text ) || StartsWith( Company, SearchInput.Text ) )

 

 

I have a similar use case on most of my selction screens, where I need to filter a gallery by multiple conditions.

 

Any help would be much appreciated,

Thank you and Cheers!

Categories:
I have the same question (0)
  • hpkeong Profile Picture
    2,944 on at

    Hi

     

    I remember I have posted a Multi-Search example in the forum.

    Anyway, let me share the concept for Multi-Search or Filter:

     

    Typically, we used to have

    - Gallery.Items = TableX

     

    Please amend to:
    - Gallery.Items = collectionx (any name is OK), where collectionx is derived from several way, such as:

    Screen.OnVisible = ClearCollect(collectionx, TableX)

     

    Now, you can have multi-search or filter using

    - Search Box 1  TextInput1.Default = ClearCollect(collectionx, Filter(TableX, your formula 1)

    - Search Box 2   TextInput2.Default = ClearCollect(collectionx, Filter(TableX, your formula 2)

     

    You can even use

    - Dropdown (ClearCollect(collectionx, your field = Dropdown.Selected.Results)

    - Listbox

    - Another Gallery

    to trigger the same.

     

    Why use ClearCollect(collectionx,......) ?

    Whenever you perform any function (filter, drowdown,..), all the resultes will be collected temporarily into collectionx and

    collectionx is used a the items for Gallery.

     

    The above method can be widely used in many situations.

     

    Hope this helps.

     

    TQ

  • Community Power Platform Member Profile Picture
    on at

    Hi @hpkeong

     

    Thank you for the reply, your help is very much appreciated!!

     

    I had been stearing clear of collections, but now is as good a time as any to use them. The amount of time to load my tables into memory is a little painful, but we will see how we go.

     

    I have tried your approach with some success, I can load collectionx (I used your naming for ease of writting) using the Screen.OnVisable property.

     

    However I cant get my text input(search box) to filter, the Defult is: 

    ClearCollect(collectionx,Filter( 'Resource Profile', StartsWith( display_name, SearchResourceName.Text ) ))

     

     

    Any suggestions?...

     

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 319 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard