Lightning Flow data table is a component that can be used within a flow to display data in a tabular format. It is similar to a traditional table and can be customized to show data from different objects or fields. The data table flow component was missing functionality to search content in it. In the summer 23 release, the search bar is added to the screen flow data table. This post will give step-by-step detail for searching text in Flow Data Table by enabling a search bar in the screen flow data table.
Steps
- Create a Data Source for the Data table
- Add the Data Table Input component in the Screen Element
- Enable Search Bar in Data Table
- Test Functionality
1. Create a Data Source for the Data table
Create a data source for the data table. For the demo, I have added Record Get Element to retrieve all accounts. You can build data collection based on your use case.
2. Add the Data Table Input component in the Screen Element
Once the data source is ready, add a screen element on the flow builder. Add Data Table input component on newly added screen element.
Set Data Table component properties
- API Name – Summer23ScreenFlow
- Label – Summer 23 Screen Flow Enhancement – Search Bar
- Use Label as the table title – checked
- Source Collection – Select the source which we have created in step 2. It is Accounts from Get_Accounts for me.
- Row Selection Mode – Single
- Require user to make a selection- Checked
- Configure Columns – Account Name (add based on your requirement)
3. Enable Search Bar in Data Table
Enable the Search bar by checking the Show search bar option in Configure Data Source section. By default this option is unchecked.
4. Test Functionality
Test the flow in debug or record page. It will search the content using the search bar. We have to enter the search text and press enter button to search text values. The filtered result will show in the data table.
References
Search and Display Data Table Results in Screen Flows
2 comments
[…] Searching Text in Flow Data Table […]
[…] Searching Text in Flow Data Table […]