cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Filter dropdown list with multi select option

Hi Team,

I Have 2 dropdown field in SharePoint list (Category and Subcategory)with multi select option. How do i filter sub category field based on category field. Both the fields have option to select multiple values. Also These fields are lookup values.

 

 

Thanks,

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Re: Filter dropdown list with multi select option

Hi @Sreeraj_r ,

 

How did you define the items property of Category dropdown?

Does the Category dropdown allow multiple selections?

I made a test on my side based on your description, and the following workaround should work for you.

1. Set Category dropdown.Items: 

Choices('SP list'. Category)

2. Set Category dropdown.OnChange: 

Clear(AID);ForAll('SP list',If(!(false in ForAll(CategoryComboBox.SelectedItems,If(Id in Category.Id,true,false))),Collect(AID,ID)))

AID is the collection storing all items'ID that meet Category dropdown selections

3. set Subcategory dropdown.Items:

Filter(Choices('SP list'.Subcategory),Id in Concat( Filter(AddColumns('SP list',"NewColumn",Concat(Subcategory,Id & " ")),ID in AID).NewColumn, NewColumn & " "))

Snipaste_2020-05-01_11-38-16.pngSnipaste_2020-05-01_11-38-28.png

Hope this helps.

Sik

 

View solution in original post

1 REPLY 1
Highlighted
Community Support
Community Support

Re: Filter dropdown list with multi select option

Hi @Sreeraj_r ,

 

How did you define the items property of Category dropdown?

Does the Category dropdown allow multiple selections?

I made a test on my side based on your description, and the following workaround should work for you.

1. Set Category dropdown.Items: 

Choices('SP list'. Category)

2. Set Category dropdown.OnChange: 

Clear(AID);ForAll('SP list',If(!(false in ForAll(CategoryComboBox.SelectedItems,If(Id in Category.Id,true,false))),Collect(AID,ID)))

AID is the collection storing all items'ID that meet Category dropdown selections

3. set Subcategory dropdown.Items:

Filter(Choices('SP list'.Subcategory),Id in Concat( Filter(AddColumns('SP list',"NewColumn",Concat(Subcategory,Id & " ")),ID in AID).NewColumn, NewColumn & " "))

Snipaste_2020-05-01_11-38-16.pngSnipaste_2020-05-01_11-38-28.png

Hope this helps.

Sik

 

View solution in original post

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Watch Now

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (4,369)