web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter gallery by mult...
Power Apps
Unanswered

Filter gallery by multi selection Sharepoint column and additional column

(0) ShareShare
ReportReport
Posted on by 2

Hi,

 

I have a gallery (‘Gallery1’) that contains items from my Sharepoint list ‘Volunteer Opportunities’. I’m trying to filter the gallery by a multi selection Choice column called ‘Location’ and includes a list of all state abbreviations in addition to a Nationwide option. Additionally I want to filter by a single Choice column called ‘Cause’.

 

I have tried a number of different ways to get this to work but the multi selection option is causing my gallery items not to populate. 

Any help would be much appreciated.


Thank you

Categories:
I have the same question (0)
  • zmansuri Profile Picture
    6,048 Super User 2024 Season 1 on at

    Gallery Item Code?

  • BCBuizer Profile Picture
    22,654 Super User 2026 Season 1 on at

    Assuming you are using ComboBoxes to select both Location and Cause, you could use the below:

     

     

     

    Filter('Volunteer Opportunities', 
    
    cmbLocation.SelectedItems.Value in Location
    
    &&
    
    cmbCause.SelectedItems.Value in Cause 
    
    )

     

     

     

     

     

     

  • JRii Profile Picture
    2 on at

    Thank you. Yes, I’m using combo boxes for both. Choices(‘Volunteer Opportunities’.Location) for the location combos box and Choices(‘Volunteer Opportunities’.Cause) for the Cause combo box. I applied the suggested formula to the Items property of my gallery but it still doesn’t display any results. 

  • Al_10 Profile Picture
    1,691 Super User 2024 Season 1 on at

    @JRii 

     

    let's say you have 2 comboboxes: 

    - comboboxCause - single choice

    - comboboxLocation - multi choice

     

    comboboxLocation has "Nationwide" option and when it is selected, all other selected states are ignored (example "nationwide", "CA", "WA" are selected, fitering will ignore "CA" and "WA" and show all states records)

     

    add a button close to those comboboxes.

     

    button.OnSelect = 

    Clear(colFilteredMultiCHoice);

    If(
    !IsBlank(comboboxLocation.Selected.Value) && !("Nationwide" in comboboxLocation.SelectedItems.Value),
    ForAll(comboboxLocation.SelectedItems As ThisLocation,
    Collect(colFilteredMultiCHoice,
    Filter('Volunteer Opportunities',
    If(!IsBlank(comboboxCause.Selected.Value),
    ThisLocation.Value in Location.Value && comboboxCause.Selected.Value = Cause.Value,
    ThisLocation.Value in Location.Value
    )
    )
    )
    )
    ,

    !IsBlank(comboboxCause.Selected.Value),
    Collect(colFilteredMultiCHoice,
    Filter('Volunteer Opportunities',
    comboboxCause.Selected.Value = Cause.Value
    )
    )
    ,

    Collect(colFilteredMultiCHoice, 'Volunteer Opportunities')

    );

    Clear(colFilteredMultiCHoice1);
    ForAll(
    Distinct(colFilteredMultiCHoice, ID),
    Collect(colFilteredMultiCHoice1, LookUp(colFilteredMultiCHoice, ID = Result))
    );
    Clear(colFilteredMultiCHoice);

     

     

     

    Gallery1.Items = colFilteredMultiCHoice1

     

     

    Screen.OnVisible = CollectCollect(colFilteredMultiCHoice1, 'Volunteer Opportunities')

     

     

     

     

    NOTE: it is not delegable. Will not work in full if your list has >500 records (or >2000 if you changed the app's settings)

     

     

     

     

     

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 914

#2
11manish Profile Picture

11manish 617

#3
Valantis Profile Picture

Valantis 598

Last 30 days Overall leaderboard