cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AKB_2K
Level: Powered On

Creating cascading distinct drop-down with additional "All" option.

Hello,

I have created a gallery named as TicketList which is populating data from SharePoint list. I have additional drop-down "Month" which shows all months in a year along with additional drop-down option "All". Selecting All option shows all items of SharePoint list whereas selecting "Month" filters the Ticket list based on item creation month. Items for this Month drop-down are being shown using a Table created during App start.

I want to create additional filter "Application" which will dynamically generate list of Applications for which ticket were raised in selected "Month". For e.g select May in first drop-down, display all applications in second drop-down. These 2 drop-down jointly filter "TicketList" gallery items.

Major road block which I am facing right now -Showing distinct values in "Application" drop-down based on "Month" drop-down selection value, along with an additional drop-down value "All". Selection of All value in either Application or Month drop-downs should show all list items in TicketList gallery.

Is this possible in PowerApps or am I asking too much?
1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Creating cascading distinct drop-down with additional "All" option.

Hi @AKB_2K ,

Do you want if the dropdown1 select May,drop down2 select Month, the gallery will display items only in May;

                     if the dropdown1 select May,drop down2 select All, the gallery will display all items?

I suggest you use if statement.

Could you tell me what's the field's data type that you want to filter according to?

I've made a similar test for yoyr reference:

I use the field named created to filter data and its data type is date.

1)Set drop down1's Items: Distinct(fruit,Month(Created))

2)Set drop down2's Items: ["all","month"]

3)Set the gallery's Items:

If(Dropdown2.Selected.Value="all",tablename,
Dropdown2.Selected.Value="month",Filter(tablename,Month(Created)=Dropdown1.Selected.Result)
)

614.png

 

 

 

Best regards,

Community Support Team _ Phoebe Liu

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Super User
Super User

Re: Creating cascading distinct drop-down with additional "All" option.

Shows us teh gallery filter to look at.

 

I do some gallery filters based on mutiple selections but it depends on the fields to be found

Community Support Team
Community Support Team

Re: Creating cascading distinct drop-down with additional "All" option.

Hi @AKB_2K ,

Do you want if the dropdown1 select May,drop down2 select Month, the gallery will display items only in May;

                     if the dropdown1 select May,drop down2 select All, the gallery will display all items?

I suggest you use if statement.

Could you tell me what's the field's data type that you want to filter according to?

I've made a similar test for yoyr reference:

I use the field named created to filter data and its data type is date.

1)Set drop down1's Items: Distinct(fruit,Month(Created))

2)Set drop down2's Items: ["all","month"]

3)Set the gallery's Items:

If(Dropdown2.Selected.Value="all",tablename,
Dropdown2.Selected.Value="month",Filter(tablename,Month(Created)=Dropdown1.Selected.Result)
)

614.png

 

 

 

Best regards,

Community Support Team _ Phoebe Liu

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
Better Together’ Contest Finalists Announced!

'Better Together’ Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Join THE global Microsoft Power Platform event series

Attend for two days of expert-led learning and innovation on topics like AI and Analytics, powered by Dynamic Communities

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

thirdimage

Microsoft Business Applications Virtual Launch

Join us for the Microsoft Business Applications Virtual Launch Event on Thursday, April 2, 2020, at 8:00 AM PST.

thirdimage

Community Summit North America

Innovate, Collaborate, Grow - The top training and networking event across the globe for Microsoft Business Applications

Top Solution Authors
Top Kudoed Authors
Users online (5,073)