Hi @Sam70
Yes, you can filter records directly within your Canvas App based on the selections made in the multi-select dropdown without using Power Automate. Here's a general outline of how you can achieve this:
-
Retrieve Account Records: Use a data source or connector in your Canvas App to retrieve the account records that you want to filter.
-
Multi-Select Dropdown: Add a multi-select dropdown control to your Canvas App. Populate this dropdown with the relevant options that users can select to filter the account records.
-
Filter Records On Selection Change: Use the OnChange property of the multi-select dropdown control to trigger filtering of account records whenever the selection changes. Within this property, write a formula to filter the account records based on the selected values from the dropdown.
-
Update Data Source: Once the records are filtered based on the selection made in the dropdown, update the data source bound to your app to display only the filtered records.
Here's a simplified example of what the formula might look like for filtering records in the OnChange property of the multi-select dropdown:
A guide line of the filter:
UpdateContext({ SelectedValues: Dropdown1.SelectedItems }); // Store selected values in a context variable
If(
IsEmpty(SelectedValues), // Check if any values are selected
Reset(AccountDataSource), // If no values are selected, reset the datasource to show all records
UpdateIf(
AccountDataSource, // Your data source
true, // Condition to update all records
!IsEmpty(Filter(SelectedValues, Value in AccountName)), // Filter condition based on selected values
false // Don't overwrite existing data
)
)