web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter a column based ...
Power Apps
Unanswered

Filter a column based on search bar

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hello!

I am having a dropdownbox that I want to filter the options using a search bar. Like this: https://gyazo.com/ec588d99054096ecf950074d4a1e7155

Database looks like this: https://gyazo.com/8af525828a38ec4ca15c4856a528d6de (Database name = Lijst_eindp

In the dropdownbox, I want all available "Prod. usage". Whenever you type something in the searchbar, I want it to filter the results. How can I do this? This is what I have tried but does not work: 

Filter(
 Lijst_Eindp.'Prod. usage';
 TekstZoekVeld_1.Text)
Categories:
  • eka24 Profile Picture
    20,925 on at

    You want to filter the dropdown using the Textbox

    Filter( Lijst_Eindp.'Prod. usage'=TekstZoekVeld_Text)

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Getting an error when I try this code: https://gyazo.com/fd63a7a3629277887cb1b7ac25730346 @eka24 

  • eka24 Profile Picture
    20,925 on at

    Is the Datasource SharePoint. Change the formula to

    Filter( Lijst_Eindp.'Prod. usage'.Value=TekstZoekVeld_Text)

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    My database is indeed Sharepoint. Still getting an error @eka24 

    https://gyazo.com/008510c9d5fd589b62651079df5271ab

  • eka24 Profile Picture
    20,925 on at

    Try

    Filter( Lijst_Eindp; TekstZoekVeld_Text in 'Prod. usage')

     

    If you have issues, replace the Textbox with a combobox and put on its items;

    Lijst_Eindp.'Prod. usage'

     

    Or if it a choice column:

    Choices(Lijst_Eindp.'Prod. usage')

     

    Then change the filter to;

    Filter( Lijst_Eindp; 'Prod. usage' in Combobox1.SelectedItems)

     

    ------------

    If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

  • v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi@TimoMigchielsen,

    Based on the issue that you mentioned, do you want to filter the gallery based on Searchbar and Dropdown?

    Could you please share more about the 'Prod. usage' column, is it a Choice or a Text column?

    I have a test on my side, please take a try as below.

    If this 'Prod. usage' column is a Text type.

    Set the Items property of the Dropdown as below:

     

    Distinct(Lijst_eindp,'Prod. usage')

     

    Set the items property of the Gallery as below.

     

    Search (Filter (Lijst_eindp, 'Prod. usage'= Dropdown1.Selected.Result),TextSearchBox1.Text,"whatever","Prod_x002e_usage")

     

    If this 'Prod. usage' column is a Choice type, well you cannot put 'Prod. usage' column in Searchbas where only supports the Text column.

    Set the Items property of the Dropdown as below:

     

    Choices('Lijst_eindp'.'Prod. usage')​

     

    Set the items property of the Gallery as below.

     

    Search (Filter (Lijst_eindp, 'Prod. usage'.Value= Dropdown1.Selected.Value),TextSearchBox1.Text,"whatever")

     

    Note: “Prod_x002e_usage” represents 'Prod. usage', it will change format when you use strange characters within the column name.0730Gif2.gif

    Best Regards,

    Qi

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Sorry for not being clear enough, I will explain it better @v-qiaqi-msft 

    I am not having a gallery. I only have a textsearchfield & and dropdown. 

    https://gyazo.com/f24c397405612b0cfa1e57b240bbef70

    I want the options in the dropdown to be filtered by what  you type in the textsearchfield. It is indeed a text value column, Prod. usage

    So whenever you type nothing and open the dropbox, you get all of the rows inside of Lijst. Eindp.Prod. usage and whenever you start typing the textfield, it filters the options that are available.

    If possible I'd also like to use the distinct function to filter out the doubles

  • v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi@TimoMigchielsen,

    Sorry for the misunderstanding. I think we almost get there. Do you want to filter the Dropdown based on the input form the search bar?

    Noted that you have a long string in each row of the 'Prod. usage', do you want to filter the option form the Dropdown whatever you enter in the search bar?

    Since 'Prod. usage' is a Text column, you can try the formula as below

    Set the Items property of the Dropdown as below

     

    If(
     IsBlank(TextInput1.Text),
     Distinct(
     Lijst_eindp,
     'Prod. usage'
     ),
     Filter(
     Distinct(
     Lijst_eindp,
     'Prod. usage'
     ),
     TextInput1.Text in Result
     )
    )

     

    Best Regards,

    Qi

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Thank you, this is working! @v-qiaqi-msft 

    Now I want the following thing added: https://gyazo.com/27633b4b1aee9c6e61381f0e344d5868

    You see 2 checkboxes, left one is (Checkbox2_1, right checkbox = Checkbox2)

    Whenever the left one is active, I want it to get all rows inside of "Omschrijving", where prod.usage = "Bev M; Montage".

    Whenever the right one is active, I want it to be default. This is the default code right now. When nothing is selected, it is empty 

     

    If(
     IsBlank(TekstZoekVeld_1.Text);
     Distinct(
     Lijst_Eindp;
     Omschrijving
     );
     Filter(
     Distinct(
     Lijst_Eindp;
     Omschrijving
     );
     TekstZoekVeld_1.Text in Result
     )
    )

     

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Check above @v-qiaqi-msft  😀

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 248 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 192 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 135

Last 30 days Overall leaderboard