Skip to main content

Notifications

Power Apps - Building Power Apps
Answered

Filter gallery searchbox and dropdown

(0) ShareShare
ReportReport
Posted on by 395

Hi, i have a gallery with with 2 filters (1 dropdown and 1 search box). The items property is set to

 

If(IsBlank(
Dropdown2.Selected.Value),PartsRequestCollection,
Search(
Filter(PartsRequestCollection,
Status.Value = Dropdown2.Selected.Value),
LookupSearch.Text,"OrderedFrom"))

 

When nothing is selected, all the gallery records are displayed, however, i cant filter the search with the LookupSearch textinput. Once i filter by dropdown, the lookupSearch textinput filters works fine.  Any suggestions on how i can get the LookupSearch to work when all records are displayed? Thanks

Categories:
  • Tan_Jia_Ying Profile Picture
    Tan_Jia_Ying 54 on at
    Re: Filter gallery searchbox and dropdown

    Hi,

    I try to get five drop-down list is "ok" at the same time, and the result of the text label is "ok". But if one of the drop-down list is "Fail", then the result of the text label is "Fail".

     

    The program I wrote did not produce errors, but the results it produced were not what I wanted. I've set the following:

     

    Drop down: Items=

    ["OK","Fail"]

     

    Text Label: Text =

    IfError((Text(Dropdown6.SelectedText.Value)&&(Dropdown7.SelectedText.Value)&&(Dropdown8.SelectedText.Value)&&(Dropdown9.SelectedText.Value)&&(Dropdown10.SelectedText.Value)),"OK","Fail")

     

    Thanks for your help!

  • Matt383 Profile Picture
    Matt383 395 on at
    Re: Filter gallery searchbox and dropdown

    Thanks Warren, that did the trick

  • Verified answer
    WarrenBelz Profile Picture
    WarrenBelz 145,580 on at
    Re: Filter gallery searchbox and dropdown

    Hi @Matt383 ,

    Try this

    Search(
     Filter(
     PartsRequestCollection,
     Len(Dropdown2.Selected.Value) = 0 ||
     Status.Value = Dropdown2.Selected.Value
     ),
     LookupSearch.Text,
     "OrderedFrom"
    )

     

    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.

    MVP (Business Applications)   Visit my blog Practical Power Apps

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,580

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,909

Leaderboard