Improving User Experience with Delayed filter or Search in Power Apps

Hello everyone and welcome to my blog. In today’s blog, I will show how you can filter a gallery or perform a search operation only after the user has finished typing in the search text.

To explain the requirement, let’s take this scenario. In the below example I am using the Search function of PowerApps to filter gallery based on the search text.

Observe the behavior in the video above. The search is performed for each keystroke. While that may be advantageous for certain scenarios, it leads to multiple calls to the DataSource as the user continue typing in the search bar. In scenarios where the DataSource size is large, this can lead to performance issues.

What if your requirement is to search only after the user has finished typing the search text? That would ensure a single call to the datasource with the search text.

Doing that is actually quite easy. And you can do that by setting the property – DelayOutput of the text input control to true.

If you set this property of the text input to true, the trigger will only happen half a second after the user has stopped typing. Check for the change of behavior after I have set the DelayOutput property of the text input control to true.

As you could see, the response was much faster and the search didn’t start until I finished typing in the search box. This ensured a single call to the datasource with the Search text.

Hope this helped.

Debajit Dutta


Discover more from Debajit's Power Apps & Dynamics 365 Blog

Subscribe to get the latest posts sent to your email.

Discover more from Debajit's Power Apps & Dynamics 365 Blog

Subscribe now to keep reading and get access to the full archive.

Continue reading