cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
diegoandre10
Post Partisan
Post Partisan

Dependent Combo box not displaying all possible choices

Hi all

 

I have dependent combo box's, bottler depends on country and country depends on region.

 

When I select multiple countries, the bottler field only displays the options for the latest country selected, not for all. 

 

To explain myself better I have this 30 seconds video:

 

https://1drv.ms/u/s!ApgeWwGTKtFdh1PABLciK2vFhdWe?e=eS7izs

 

As seen on bottler choices, it only shows the values for either Colombia or Peru, but not both.

 

I have 2 SP lists. One for the dependent dropdowns (Facilities_LATAM) and the one that stores the responses (BCP LATAM):

addsfsdf.pnglsdkfs;ldk1.JPG

 

The code is the following:

 

Items:

 

itens1.png

 

OnChange:

OnChange.png

 

DefaultSelectedItems:

 

default.png

 

Display Mode: all have same "Parent.DisplayMode":

 

sdlfjs.JPG

 

How can I get it to work?

 

Thanks!

 

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

@diegoandre10 ,

What I posted - you need to change 

Country = ComboBoxCountry.Selected.Result

to

Country in ComboBoxCountry.SelectedItems

if you want to have everything matching multiple selections in the combo box.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

View solution in original post

8 REPLIES 8
WarrenBelz
Super User
Super User

Hi @diegoandre10 ,

I will deal with one of these - if you have multiple selected Items, you need this syntax

Distinct(
   Filter(
      Facilities_LATAM,
      Country in ComboBoxCountry.SelectedItems
   ).Bottler,
   Bottler
)

Note however this is not Delegable.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Hi @WarrenBelz 

 

Thanks for the response. I tried your code under items for the bottler combo box but I got an error:

 

dsds;lkfds;.JPG

 

sdf1.JPG

 

Is it supposed to go on items or somewhere else?

 

Thanks. 

@diegoandre10 ,

Free-typed code - try it now (although I was only showing you the change in syntax and thought you might have picked it up).

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Hi @WarrenBelz 

 

Not sure I understand where to enter the free code. Can you please explain me how to make the dropdown show all the values?

 

Here is the code for items I had:

 

ComboBoxCountry:

 

 

Distinct(Filter(Facilities_LATAM,Title = ComboBoxRegion.Selected.Result).Country,Country)

 

 

ComboBoxBottler:

 

Distinct(Filter(Facilities_LATAM,Country = ComboBoxCountry.Selected.Result).Bottler,Bottler)

 

 

Thanks!

@diegoandre10 ,

What I posted - you need to change 

Country = ComboBoxCountry.Selected.Result

to

Country in ComboBoxCountry.SelectedItems

if you want to have everything matching multiple selections in the combo box.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

View solution in original post

Hi @WarrenBelz 

 

Seems to have worked, thanks. But there is a warning: delegation warning. The highlighted part of this formula might not work correctly on large data sets.

 

salkjdlakjsd.JPG

 

 

Change the item to the right of the "in" operator to be a column from the correct data source. 

If your data set exceeds the 500 record limit but contains less than 2,000 records, try resetting the limit. 

Try simplifying the formula. Try moving your data to a different data source.

 

 

Should I be concerned? I will definitely have lots of records on my SP List.

 

Thanks again !!

 

@diegoandre10 ,

I was almost going to mention that (but assumed you might know this). The in operator is not Delegable, but is the only way of getting the values from a multi-select control. I have a blog on Delegation that might be useful to you.

 

Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

Thanks for the explanation @WarrenBelz , you're the BOSS 🙂

 

Appreciate your help.

 

Diego.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

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