Showing results for 
Search instead for 
Did you mean: 
Not applicable

Multiple Search filter boxes for the same sharepoint gallery

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!

Community Champion
Community Champion



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.



Not applicable

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?...


Helpful resources

UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Top Kudoed Authors
Users online (2,813)