cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

ComboBox DefaltSelectedItems shows Duplicate Items Selected

Setting DefaultSelectedItems in a Combo Box shows multiple items selected if the label (values) are identical irrespective of these having different Ids.
Example: In my list options I have three items as follows:

ID   Value

  1.     EUCAN
  2.     EEMEA
  3.     EUCAN (this item has duplicate label as #1)

I initiate a variable to hold back the selection values of this Combo Box as varSelectedRegions. Based on other drop down values, I have the varSelectedRegions as {{EUCAN, 1}, {EEMEA, 2}} i.e. two items saved in the variable as selection. 

I use the following formula in DefaultSelectedItems to show selected items in the Combo Box:

ForAll(varSelectedRegions, {Value: Value, Id: Id })

The items are displayed as selected in the Combo Box but not only #1 and #2 - #3 as well as it has same label as one of the selections I've set. Though when I save this item in the list, column values are selected correctly as #1 and #2.

Is there something I'm doing wrong here or this is a defect in displaying the selected items in the Combo Box which does not take Id in account?

4 REPLIES 4
Highlighted
Super User III
Super User III

Re: ComboBox DefaltSelectedItems shows Duplicate Items Selected

@ShobhitDeep 

Actually what you are seeing is related more to the search part - and I would actually consider it a bit of a design flaw/bug.

 

The reality is, your selected items are correct and only address the ID 1 and ID 2.  ID 3 is not really selected, it just appears that way - I believe because of the way that the control displays and highlights.  

 

The only real way around it would be to have unique items in the combobox.  Which is really what you want.  Because, from a user standpoint, if you see a list of items that have the same names...which one would you pick?  How would I know that the first one is ID 1 and the last one is ID 3?

 

I hope this is helpful for you.

 

 

 

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Highlighted
Regular Visitor

Re: ComboBox DefaltSelectedItems shows Duplicate Items Selected

@RandyHayes : Correct; completely agree with your logic. In actual scenario having two items with same title will not be a reasonable implementation. In fact this defect is also discovered due to a defect in my implementation. I already fixed my defect and dont have any duplicate title items anymore...

 

Highlighted
Super User III
Super User III

Re: ComboBox DefaltSelectedItems shows Duplicate Items Selected

@ShobhitDeep 

Yes, the more that I thought about it after I replied...the more I realized it would definitely not be something you would want.

Like a list of colors and two "Red"s listed....then telling the user they picked the wrong "Red".  Not so good.

Anyway, glad you got it sorted out.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up. Solved your problem? - Click on Accept as Solution. Others seeking the same answers will be happy you did.
Highlighted
Regular Visitor

Re: ComboBox DefaltSelectedItems shows Duplicate Items Selected

@RandyHayes :

 

Correct! Though a technical defect, we can call it a usability feature! LOL!

😁 😂 😋

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

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