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):
The code is the following:
Items:
OnChange:
DefaultSelectedItems:
Display Mode: all have same "Parent.DisplayMode":
How can I get it to work?
Thanks!
Solved! Go to Solution.
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.
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:
Is it supposed to go on items or somewhere else?
Thanks.
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!
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.
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.
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 !!
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.
User | Count |
---|---|
251 | |
102 | |
94 | |
47 | |
37 |