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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter several choice ...
Power Apps
Unanswered

Filter several choice values in a dropdown list based upon another value

(1) ShareShare
ReportReport
Posted on by 6

I have a SharePoint column that has about 8 Choice values in it (you can only select one).  There's another 

Based upon a previous selection in the Canvas form, I want to filter out 2 items if you pick one value from another Choice column (column B) and another item if you pick an alternate value from Column B.

This is what I have so far, which successfully filters the single item from my dropdown list, if I pick a specific value in Column B, in the Items field:
With(_items:Choices([@'splist here'},'Name of SP list')
  },
  If(DataCardValue9.Selected.Value = "Remote", Filter(_items,Value<>"In Office Issue"),_items
  )
)

So that works for the 2nd half of my request.  What I am thrown off on, is how I add a second "If" statement where the selected value = "something else" and filters out two other values from the dropdown list instead.

I tried a switch command based upon some other searches, but that didn't work.  I also tried to work around using "<>", but that doesn't seem to be the issue either.  

Most of my searches only turn up results for filtering a single item.  If I search for multiple, it references "multiple choice" columns, which isn't what I'm dealing with here.

I'm assuming my approach to this is probably wrong, so any guidance would be appreciated.  If I knew this form would have this much complexity, I would have pursued alternate designs for these columns of data, but am just trying to make it work.  

Categories:
I have the same question (0)
  • Michael E. Gernaey Profile Picture
    53,928 Super User 2025 Season 2 on at

    Hi @tullnd 

     

    So bare with me and tell me since im writing it pseudo code 

     

    Add your filter built up
    With(_items:Choices([@'splist here'},'Name of SP list')
     },
     If(DataCardValue9.Selected.Value = "Remote", 
     If(MyOtherDataCard.Selected.Value = "MyOther Value",
     Filter(_items, Value<>"In Office Issue" And Value<>"OtherValue1" And Value<>"OV2" )
     ,
     Filter(_items,Value<>"In Office Issue")
     )
     ,
     If(MyOtherDataCard.Selected.Value = "MyOther Value",
     Filter(_items, Value<>"OtherValue1" And Value<>"OV2" )
     ,
     _items
     )
     ) 
    )

    Cheers,


    If I have helped you, I would really appreciate if you please Mark my answer as Resolved/Answered, and give it a thumbs up, so it can help others

    Cheers

    Thank You
    Michael Gernaey MCT | MCSE | MCP | Self-Contractor| Ex-Microsoft
    https://gernaeysoftware.com
    LinkedIn: https://www.linkedin.com/in/michaelgernaey

  • tullnd Profile Picture
    6 on at

    Hi, so I think that's similar to what I'm after.

    With Column B, if I answer "Remote", I want to filter one item in Column A Dropdown display.
    If I answer "In office" in Column B, I want to filter two different items in Column A dropdown diplay.

    So I'm not using two distinct columns, just one "DataCardValue9" but it can be two different values, resulting in two different filters being applied.

    I'm going to try and mess with your arrangement a bit and see if I can get it to work though.

  • tullnd Profile Picture
    6 on at

    I'm still at a loss.  I can't get any variations of the above code to work.

    To clarify what I need, I have two boxes, fed by SP List choice columns.  If Value X is selected in Column A, I want to filter one item/value from appearing in the dropdown (it's actually a combobox in the form) of choices that's fed by Column B.

    If you select Value Y is the combobox fed by Column A, I want to hide a different item/value from appearing in the dropdown combobox fed by Column B.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Apps

#1
Kalathiya Profile Picture

Kalathiya 402

#2
WarrenBelz Profile Picture

WarrenBelz 380 Most Valuable Professional

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 293 Super User 2025 Season 2

Last 30 days Overall leaderboard