cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DustinB
Advocate I
Advocate I

Filter independent search in Gallery

Hi everyone,

 

is it possible to build a "global" search for a collection? 

The search should be Filter independent, so if a Filter is selected the Search should find every item in the gallery.

 

I'm currently using this function for my gallery:

SortByColumns(Search(Filter([...]); Textinput.Text; [outsource column]); "Sortnumber"; Ascending)

1 ACCEPTED SOLUTION

Accepted Solutions
WarrenBelz
Super User
Super User

Hi @DustinB ,

You need to use the in Filter (which is the same result as Search) and an Or() argument || as below - so it is looking for either your filter or what you are searching for

SortByColumns(
   Filter(
      YourDataSource,
      (YourCurrentFilterHere) ||
      TextInput.Text in YourSearchField
   )
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

View solution in original post

3 REPLIES 3
Nogueira1306
Super User
Super User

Hey! Check this video:

 

https://www.youtube.com/watch?v=PsQhuX7WEbo&t=3s 

 

Basically:

 

If( IsBlank(TextInput1.Text = true; SortByColumns(Search(Filter([...]); Textinput.Text; [outsource column]); "Sortnumber"; Ascending); HERER USE THE FUNCTION FROM THE VIDEO WITH STARTSWITH)

 

If you need additional help please tag me in your reply and please like my reply.
If my reply provided you with a solution, pleased mark it as a solution ✔️!

Best regards,
Gonçalo Nogueira

Check my LinkedIn!

WarrenBelz
Super User
Super User

Hi @DustinB ,

You need to use the in Filter (which is the same result as Search) and an Or() argument || as below - so it is looking for either your filter or what you are searching for

SortByColumns(
   Filter(
      YourDataSource,
      (YourCurrentFilterHere) ||
      TextInput.Text in YourSearchField
   )
)

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

 

 

Thank you! 

Unfortunately it doesn't work for my case, because the gallery should only display the current Filter and should optional show the Item(s) when the searchbox is filled

 

I'm trying to realise this with a few if conditions... 🙂

 

 

Helpful resources

Announcements
Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Top Kudoed Authors
Users online (3,084)