cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
TesDA
Continued Contributor
Continued Contributor

Cascading drop down only if populated in item along with other columns

I have 4 drop downs in a edit form:

 

Matter - Matter_DropDown

Assignment LOB Description - LOB_DropDown

SIC (visible/ required only if Matter = Tax or Matter = Business Advisory Services) -SIC_DropDown

Client Name/ Assignment - Client_CardValue

 

Client Name is a selection that is filtered down by all above it: Matter, Assignment LOB, SIC).

 

How do I write the items so that it only filters for SIC if Matter = Tax or Matter = Business Advisory Services?

 

This is what I have right now:

 

Client_CardValue - Items:

 

Distinct(

  Sort(

    Filter(

      '[dbo].[vps_App_ICWO_HCM_CA_Client]',

      MATT_CAT_CODE_Desc = Matter_DropDown.SelectedText.Result &&

        Assignment_LOB_Desc = LOB_DropDown.Selected.Result), CLIENT_NAME), CLIENT_NAME)

1 ACCEPTED SOLUTION

Accepted Solutions
v-xida-msft
Community Support
Community Support

Hi @TesDA ,

Could you please share a bit more about your scenario?

Do you want to add the SIC_Dropdown filter to your current Filter formula only when the Matter = Tax or Matter = Business Advisory Services?

 

Based on the needs that you mentioned, I think the If function could achieve your needs. Please consider take a try with the following workaround:

Set the Items property of the Client_CardValue to following:

Distinct(
         Sort(
               Filter(
                     '[dbo].[vps_App_ICWO_HCM_CA_Client]',
                      MATT_CAT_CODE_Desc = Matter_DropDown.SelectedText.Result,
                      Assignment_LOB_Desc = LOB_DropDown.Selected.Result,
                      If(
                          Matter_DropDown.SelectedText.Result = "Tax" || Matter_DropDown.SelectedText.Result = "Business Advisory Services",
                          SIC_Desc = SIC_DropDown.SelectedText.Result,  // SIC_Desc represenrs the field in your data source, please replace it with actual column name
                          true
                      )
               ), 
               CLIENT_NAME
         ), 
         CLIENT_NAME
)

 

If you want to hide the SIC data card in your Edit form, please try the following workaround:

Set the Visible property of the SIC data card in your Edit form to following:

If(
   Matter_DropDown.SelectedText.Result = "Tax" || Matter_DropDown.SelectedText.Result = "Business Advisory Services",
   true,
   false
)

 

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
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

1 REPLY 1
v-xida-msft
Community Support
Community Support

Hi @TesDA ,

Could you please share a bit more about your scenario?

Do you want to add the SIC_Dropdown filter to your current Filter formula only when the Matter = Tax or Matter = Business Advisory Services?

 

Based on the needs that you mentioned, I think the If function could achieve your needs. Please consider take a try with the following workaround:

Set the Items property of the Client_CardValue to following:

Distinct(
         Sort(
               Filter(
                     '[dbo].[vps_App_ICWO_HCM_CA_Client]',
                      MATT_CAT_CODE_Desc = Matter_DropDown.SelectedText.Result,
                      Assignment_LOB_Desc = LOB_DropDown.Selected.Result,
                      If(
                          Matter_DropDown.SelectedText.Result = "Tax" || Matter_DropDown.SelectedText.Result = "Business Advisory Services",
                          SIC_Desc = SIC_DropDown.SelectedText.Result,  // SIC_Desc represenrs the field in your data source, please replace it with actual column name
                          true
                      )
               ), 
               CLIENT_NAME
         ), 
         CLIENT_NAME
)

 

If you want to hide the SIC data card in your Edit form, please try the following workaround:

Set the Visible property of the SIC data card in your Edit form to following:

If(
   Matter_DropDown.SelectedText.Result = "Tax" || Matter_DropDown.SelectedText.Result = "Business Advisory Services",
   true,
   false
)

 

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

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

Helpful resources

Announcements
Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Super User 2 - 2022 Congratulations

Welcome Super Users

The Super User program for 2022 - Season 2 has kicked off!

September Events 2022

Check out all of these events

Attend in person or online, there are incredible conferences and events happening all throughout the month of September.

Government Carousel

New forum: GCC, GCCH, DoD - Federal App Makers (FAM)

In response to the unique and evolving requirements of the United States public sector, Microsoft has created Power Apps US Government.

Users online (2,748)