Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Widgets - General questions or Mixed problems » BUG? DropList shows first of entries with same key
Re: BUG? DropList shows first of entries with same key [message #32201 is a reply to message #32143] Sat, 30 April 2011 13:12 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
kohait00 wrote on Wed, 27 April 2011 11:34

hi
a DropList with such entries
	dl.Add(100, "Apple");
	dl.Add(100, "Cherry");
	dl.Add(101, "Pear");
	dl.Add(100, "Berry");

will always show 'Apple' even if Cherry or Berry are selected.
it's due to Sync() method which key.Find()'s the value of the first entry only..(typical Map/Index behaviour).

it'd be great to be able to select the entries independantly, even if they got the same key..

is that possible somehow?


Its a feature. In fact, correct solution would be ASSERT that ensures that the key is unique.

The value of DropList is defined by key. Value is just for display reason.
 
Read Message
Read Message
Read Message
Previous Topic: static Ctrl causes running failure
Next Topic: Wanted : Graphic designer
Goto Forum:
  


Current Time: Wed May 08 14:39:56 CEST 2024

Total time taken to generate the page: 0.02631 seconds