Post

#PowerPlatformTip 23: 'Filter Blank'

#PowerPlatformTip 23: 'Filter Blank'
TL;DR: Add   IsBlank(YourFilterInput) to a gallery’s Filter so it shows every item when the search box is empty.

💡 Challenge

Filtering galleries in PowerApps based on user input (like text input, dropdown, or combo box) is common, but when the input is empty you usually want to show all items.

✅ Solution

Add an || IsBlank(YourFilterInput) condition to your filter formula.

🔧 How It’s Done

  1. Create a gallery and set up your filter inputs (e.g., text input, dropdown, combo box).

  2. Apply the following formula to your gallery’s Items property:

    1
    
    Filter(YourDataSource, Condition || IsBlank(YourFilterInput))
    

    🔸 YourDataSource is the source of your data.

    🔸 Condition is your filtering condition (e.g., TextInput.Text = ThisItem.Field).

    🔸 YourFilterInput is the input control (e.g., TextInput, Dropdown).

🎉 Result

When the filter input is empty, the gallery shows all items. If the input is provided, the gallery filters based on the specified condition.

🌟 Key Advantages

🔸 Simplifies gallery filtering logic.

🔸 Enhances user experience by dynamically displaying all or filtered data.

🔸 Reduces the need for multiple filtering conditions.

🔸 #PowerPlatformTip 33: ‘Coalesce’ - replace nested If(IsBlank()) checks elsewhere in the same app with one function.

🔸 #PowerPlatformTip 38: ‘Data Refresh’ - keep this gallery’s data fresh without reloading everything on every keystroke.

🎥 Video Tutorial


🛠️ FAQ

1. Can I use multiple filter conditions with the IsBlank() check?

Yes, you can combine multiple conditions using && or   operators while still including the IsBlank() check for each filter input.

2. Does this technique work with all data sources in PowerApps?

Yes, this filtering approach works with SharePoint lists, Dataverse tables, SQL databases, and other supported data sources.

3. How can I handle multiple filter inputs simultaneously?

Create compound conditions like: Filter(DataSource, (Condition1 || IsBlank(Input1)) && (Condition2 || IsBlank(Input2))).


This tip is by Marcel Lehmann, Microsoft MVP (Business Applications) and founder of the Power Platform Academy – live Power Platform workshops, free or CHF 49. Join the workshop waitlist to get notified about new dates. For companies that want this implemented for them, see KMUpower – Power Platform consulting & automation for SMEs (DACH).

This post is licensed under CC BY 4.0 by the author.

Microsoft and the Power Platform product names (for example Power Apps, Power Automate, Copilot Studio) are trademarks of the Microsoft group of companies. This is an independent website. It is not operated, sponsored or endorsed by Microsoft.