cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Filter a Gallery by "Does Not Contain" or "Not Like"

I have a Gallery that is connected to a Sharepoint List, and it is filtering based on what is entered into TextInput1 text box. So far the Items property of the gallery is set to :

Sort(Filter('Computer Tracker',StartsWith(Owner_x0020_First_x0020_Name,TextInput1.Text)||StartsWith(Owner_x0020_Last_x0020_Name,TextInput1.Text)),ID,Descending)

 

This is working fine, but I also need to hide gallery entries whose Owner_x0020_First_x0020_Name field is "Discarded". The options I have tried have not worked. Can someone help with this formula?

 

Thanks,

Andy

 

1 ACCEPTED SOLUTION

Accepted Solutions
CarlosFigueira
Power Apps
Power Apps

You can try the formula below:

SortByColumns(
    Filter(
        'Computer Tracker',
        Owner_x0020_First_x0020_Name <> "Discarded",
        StartsWith(Owner_x0020_First_x0020_Name, TextInput1.Text) ||
            StartsWith(Owner_x0020_Last_x0020_Name,TextInput1.Text)),
    ID,
    Descending)

In a Filter expression, you can pass multiple conditions, and it will only return those items that match all of the conditions.

View solution in original post

2 REPLIES 2
CarlosFigueira
Power Apps
Power Apps

You can try the formula below:

SortByColumns(
    Filter(
        'Computer Tracker',
        Owner_x0020_First_x0020_Name <> "Discarded",
        StartsWith(Owner_x0020_First_x0020_Name, TextInput1.Text) ||
            StartsWith(Owner_x0020_Last_x0020_Name,TextInput1.Text)),
    ID,
    Descending)

In a Filter expression, you can pass multiple conditions, and it will only return those items that match all of the conditions.

View solution in original post

Anonymous
Not applicable

Thanks! That helped.

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

secondImage

Power Apps Community Call

Please join us on Wednesday, October 20th, at 8a PDT. Come and learn from our amazing speakers!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Welcome Super Users.jpg

Super User Season 2

Congratulations, the new Super User Season 2 for 2021 has started!

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

Top Solution Authors
Top Kudoed Authors
Users online (1,461)