Skip to main content

Notifications

Power Apps - Building Power Apps
Answered

Powerapps Filter and Search Gallery

(0) ShareShare
ReportReport
Posted on by 34

Hi,

 

Would like to do a filtering with the condition below:

a) ListOwner.Value = CurrentUserListOwner

b) Status.Value = Dropdown1.Selected.Value

c) wildcard search in MvNo, if searchTextbox.Text is blank display all the items with condition (a) and (b) 

jshuang_1-1718343441964.png

 

 

jshuang_0-1718343354414.png

By using the Filter function below, able to fulfill condition (a) and (b) mentioned above.

Gallery Items Properties: Filter(VehicleList, ListOwner.Value = CurrentUserListOwner && Status.Value = Dropdown1.Selected.Value)


Would like to do the filtering with all the 3 conditions above (wildcard search in MvNo, if searchTextbox.Text is blank display all the items with condition (a) and (b))

 

  • CU14010518-0 Profile Picture
    CU14010518-0 34 on at
    Re: Powerapps Filter and Search Gallery

    Hi @v-xiaochen-msft 

     

    700+ as for now.

  • CU14010518-0 Profile Picture
    CU14010518-0 34 on at
    Re: Powerapps Filter and Search Gallery

    Hi @WarrenBelz 

     

    This works for me!! Thank you!

  • Re: Powerapps Filter and Search Gallery

    Hi @jshuang ,

     

    May I ask how many items do you have in this list?

     

    Best Regards,

    Wearsky

  • WarrenBelz Profile Picture
    WarrenBelz 145,422 on at
    Re: Powerapps Filter and Search Gallery

    @jshuang ,

    Dangers of free-typing code - please see amended post.

  • CU14010518-0 Profile Picture
    CU14010518-0 34 on at
    Re: Powerapps Filter and Search Gallery

    Hi 

     

    Thanks for the reply.

     

    however i hit this error 

    jshuang_2-1718346340528.png

     

  • CU14010518-0 Profile Picture
    CU14010518-0 34 on at
    Re: Powerapps Filter and Search Gallery

    Hi

     

    Thanks for the reply. 

     

    However, when i tried to search the MvNo it not showing the item

    jshuang_0-1718346163000.png

     

    without searching be like

    jshuang_1-1718346211460.png

     

  • Verified answer
    WarrenBelz Profile Picture
    WarrenBelz 145,422 on at
    Re: Powerapps Filter and Search Gallery

    Hi @jshuang ,

    Try this - the structure is to give you some degree of Delegation

    With(
     {
     _Data:
     Filter(
     VehicleList, 
     ListOwner.Value = CurrentUserListOwner && 
     Status.Value = Dropdown1.Selected.Value
     )
     },
     Search(
     _Data,
     SearchTextbox.Text,
     MVNo
     )
    )

     

    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

  • Re: Powerapps Filter and Search Gallery

    Hi @jshuang ,

     

    Please try this

    If(IsBlank(searchTextbox.Text),
    Filter(VehicleList, ListOwner.Value = CurrentUserListOwner && Status.Value = Dropdown1.Selected.Value),
    Filter(VehicleList, ListOwner.Value = CurrentUserListOwner && Status.Value = Dropdown1.Selected.Value&& searchTextbox.Text in MvNo)
    ) 

     

    Best Regards,

    Wearsky

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,422

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,711

Leaderboard