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

Filter galley using 3 different dropdowns... need help on the items property formula

Good afternoon everybody! I am tasked with adding 3 filters to the gallery screen in a canvas app here at work. I'm using a collection as my data source (you guys gave me that idea... to avoid delegation issues). The gallery looks great, and the search box I added already is working great. I want to give my users the ability to filter the gallery using 3 dropdowns: Category, Group, and Audience. The current Items property on my gallery is: 

Filter(Collection1,Category = CategoryDD.Selected.Result)

 

This works. When I preview the app, and make a selection in the Category dropdown, the items that have that particular category appear as expected. I need to add the same logic for the Group (GroupDD) and Audience (AudienceDD) dropdowns, but I don't know how to do it. I feel like there should be a way to do an "And", but maybe I'm barking up the wrong tree. I'd appreciate any feedback. Thanks guys!!

 

3 REPLIES 3
v-yujincui-msft
Community Support
Community Support

Hi @TMaith ,

 

Maybe you could try the following formula:

 

Filter(Collection1,Category =CategoryDD.Selected.Result,Group=GroupDD.Selected.Result,Audience =AudienceDD.Selected.Result)

 

vyujincuimsft_0-1663904137287.png

vyujincuimsft_1-1663904143258.png

 

 

 

Best Regards,

Charlie Choi

I tried the formula, but it did not work. And I don't know why. 

DiegoEscobar2
Helper II
Helper II

Hi @TMaith , I think you must use the expression that @v-yujincui-msft mentioned, but each condition separated by && if all conditions must match.

Hope this works.

Cheers!

Diego.

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Top Solution Authors
Top Kudoed Authors
Users online (1,278)