How to Filter Power Apps Gallery Based On Combo Box Selection? [With Real Examples]

Yesterday, someone from my team asked me whether it was possible to filter the Power Apps gallery based on multiple Combo box values. Yes, of course, achieving it is possible and very easy.

In this article, I will explain how to filter Power Apps gallery based on Combo box selection along with the topics below:

  • Filter Power Apps gallery with multiple Combobox values
  • Power Apps filter gallery based on Combo box multi-selected item
  • Filter Power Apps gallery using Combo box allows multiple selections

Filter Power Apps Gallery Based On Combo Box Selection

Let’s see how to filter a Power Apps gallery based on the combo box value with a simple scenario:

I have a SharePoint list [Loan Approval] that has various columns like:

Column NameData Type
NameIt is a default title column, I just renamed it as “Name”
CountryLookup
Loan TypeChoice [“Car Loan”, “Home Loan”, “Gold Loan”]
Loan Applied DateDate and time
Approved or NotYes/No
Loan Handled ByPerson or group
Eligibility ProvidedChoice [“Passport”, “Utility Bill”, “Voter registration card”]
Power Apps Combo box filter gallery

On my Power Apps screen, I have added a Combo box control and a Gallery control. The combo box is connected to a SharePoint list column [Country]. The gallery filters and displays the respective records whenever a user selects any value from the combo box control.

create a qna bot in azure

Follow the below steps to achieve this:

Distinct('Loan Approval',Country.Value)

Where,

  1. Loan Approval = SharePoint list name
  2. Country = SharePoint list column name
Filter gallery based on combo box in Power Apps
  • Now, we want to display the SharePoint list records based on the selected value of the combo box. For that, insert a Gallery control -> Set its Items property to:
Filter(
    'Loan Approval',
    IsBlank(cmb_Country.SelectedItems.Value) || IsEmpty(cmb_Country.SelectedItems.Value) || Country.Value = cmb_Country.Selected.Value
)

Where,

  1. Loan Approval = SharePoint list name
  2. cmb_Country = Combo box control name
  3. Country = SharePoint list lookup column
Filter Power Apps gallery based on combo box
  • Once your app is ready, save, publish, and preview it. When the user selects any value from the combo box control, the gallery will filter and display all records based on the value selected by the combo box.
add links to top link bar in sharepoint

This is how to filter a gallery control based on the combo box selected value in Power Apps.

Filter Power Apps Gallery Based On Multiple Combo Box Values

This section will explain how to control the gallery based on multiple combo box values.

My Power Apps screen has two Combo box controls and a Gallery control. The first combo box is connected to the SharePoint list choice column. The other combo box is connected to the same above SharePoint list person column [Loan Handled By].

Whenever a user selects a value from both combo box controls, the gallery control filters and displays only the data that matches both the selected items from the combo box controls, as shown below:

Power Apps Combo Box Filter Gallery

To work around this, follow the below-mentioned steps:

  • On the Power Apps screen, insert a First Combo box control -> Set its Items property to:
Distinct('Loan Approval','Loan Type'.Value)

Where,

  1. Loan Approval = SharePoint list name
  2. Loan Type = SharePoint list choice column name
Filter gallery with multiple combo box in Power Apps
  • Next, insert the second Combo box control -> Set its Items property to:
Distinct('Loan Approval','Loan Handled By')

Where,

  1. Loan Approval = SharePoint list name
  2. Loan Handled By = SharePoint list person column name
Filter Power Apps gallery with multiple combo box
  • We want to display the SharePoint list records based on the values selected by both combo boxes. For that, insert a Gallery control -> Set its Items property to:
Filter(
    'Loan Approval',
    (cmb_LoanType.Selected.Value in 'Loan Type'.Value && cmb_LoanHandledBy.Selected.Value in 'Loan Handled By')
)

Where,

  1. Loan Approval = SharePoint list name
  2. cmb_Loan Type = 1st Combo box control name
  3. Loan Type = SharePoint list choice column name
  4. cmb_LoanHandledBy = 2nd Combo box control name
  5. Loan Handled By = SharePoint list person column name
How to filter Power Apps gallery with multiple combo box
  • Save, Publish, and Preview the app. When the user selects a value from both combo box controls, the gallery will filter and display the data that satisfies both combo box selected items.
Power Apps filter gallery control based on Combo box selected value

This is how to filter a gallery with multiple combo boxes in Power Apps.

Power Apps Filter Gallery Based On Combo Box Multiple Selected Items

I will show you how to filter a Power Apps gallery based on the multiple selected items from the combo box control.

The Power Apps screen has a Combo box control and a Gallery control. The combo box is connected to the SharePoint list choice column [Loan Type] above.

Whenever a user selects multiple values from the combo box controls, the gallery filters and displays the records based on the multiple selected values of the combo box controls.

Power Apps filter gallery based on combo box multiple selected items

Follow the below steps to achieve this:

  • On the Power Apps screen, insert a Combo box control -> Set its Items property to:
Choices('Loan Approval'.'Loan Type')

Where,

  1. Loan Approval = SharePoint list name
  2. Loan Type = SharePoint list choice column name
How to filter Power Apps gallery based on combo box multiple selected items
  • On the combo box properties pane, enable the toggle switch for Allow Multiple selection as shown below:
Power Apps filter gallery using combo box
  • We want to display the SharePoint list records based on multiple combo box-selected values. For that, insert a Gallery control -> Set its Items property to:
Filter(
    'Loan Approval',
    IsBlank(cmb_MultipleLoanType.SelectedItems.Value) || IsEmpty(cmb_MultipleLoanType.SelectedItems.Value) || 'Loan Type' in cmb_MultipleLoanType.SelectedItems
)

Where,

  1. Loan Approval = SharePoint list name
  2. cmb_MutipleLoanType = Combo box control name
  3. Loan Type= SharePoint list choice column name
cannot complete this action error in sharepoint
  • Save, Publish, and Preview the app. When the user selects multiple values from the combo box control, the gallery will filter and display the records based on multiple selected values.
How to filter a Power Apps gallery using a Combo box

We can filter the Power Apps gallery based on the multiple selected items from the combo box control.

Power Apps Filter Gallery Using a Combo box that Allows Multiple Selections

Here, I will show you how to filter the Power Apps gallery using a combo box that allows multiple selections.

Per my SharePoint list [Loan Approval], I have a choice column [Eligiblity Provided] that allows multiple values.

Filter gallery using combo box in Power Apps

Now, in my Power Apps screen, there is a Combo box control connected to the above SharePoint list choice column [Eligiblity Provided].

Whenever a user selects multiple values from the combo box control, the gallery should filter based on a SharePoint list of records with multiple values and display the relevant records.

Filter gallery using a Power Apps combo box that allows multiple selections

To achieve it, follow the below steps:

  • On the Power Apps screen, insert a Combo box control -> Set its Items property to:
Choices('Loan Approval'.'Eligibility Provided')

Where,

  1. Loan Approval = SharePoint list name
  2. Eligibility Provided = SharePoint list choice column name
How to filter gallery based on Combo box in Power Apps
  • Now, we want to display the SharePoint list records based on multiple combo box-selected values. For that, insert a Gallery control -> Set its Items property to:
Filter(
    'Loan Approval',
    Concat(
        cmb_Eligibility.SelectedItems,
        Value,
        ","
    ) in Concat(
        'Eligibility Provided',
        Value,
        ","
    )
)

Where,

  1. Loan Approval = SharePoint list name
  2. cmb_Eligibility = Combo box control name
  3. Eligibility Provided= SharePoint list choice column name
Combo box filter gallery in Power Apps
  • Save, Publish, and Preview the app. When the user selects multiple values from the combo box control, the gallery will filter and display the relevant records based on multiple selected values.
Power Apps filter gallery using combo box multiple selected items

We can filter the Power Apps gallery using a combo box that allows multiple selections.

Conclusion

I hope this article helped you learn how to filter a Power Apps gallery based on a Combo box value, filter a Power Apps gallery based on multiple combo boxes, and more, with various examples.

You may also like:

>

Build a High-Performance Project Management Site in SharePoint Online

User registration Power Apps canvas app

DOWNLOAD USER REGISTRATION POWER APPS CANVAS APP

Download a fully functional Power Apps Canvas App (with Power Automate): User Registration App

Power Platform Tutorial FREE PDF Download

FREE Power Platform Tutorial PDF

Download 135 Pages FREE PDF on Microsoft Power Platform Tutorial. Learn Now…