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 » DropList new When... action request
DropList new When... action request [message #49372] Wed, 31 January 2018 22:29 Go to next message
forlano is currently offline  forlano
Messages: 1189
Registered: March 2006
Location: Italy
Senior Contributor
Hello,

I am working with a DropList. I am missing two useful When... callbacks:

WhenSelected : it should be activated after an item has been selected (WhenDrop is activated before the selection);

WhenChange : it should be activated only when the index of the drop ctrl is changed after a selection.

Does anybody has already coded them in some derived class?
Thanks,

Luigi

[Updated on: Wed, 31 January 2018 22:30]

Report message to a moderator

Re: DropList new When... action request [message #49409 is a reply to message #49372] Tue, 06 February 2018 09:43 Go to previous messageGo to next message
Oblivion is currently offline  Oblivion
Messages: 1094
Registered: August 2007
Senior Contributor
Hello Luigi,

Did you try WhenAction? AFAIK, it is activated after the selection/change, and it can work for both WhenSelected and WhenChange. (You can simply set a conditional branch for change detection in it)

Best regards,
Oblivion




Re: DropList new When... action request [message #49416 is a reply to message #49409] Tue, 06 February 2018 20:16 Go to previous messageGo to next message
forlano is currently offline  forlano
Messages: 1189
Registered: March 2006
Location: Italy
Senior Contributor
Oblivion wrote on Tue, 06 February 2018 09:43

Did you try WhenAction? AFAIK, it is activated after the selection/change, and it can work for both WhenSelected and WhenChange. (You can simply set a conditional branch for change detection in it)


Hi Oblivion,

thanks for the answer.
Yes, WhenAction is activated after the selection. So, half problem is solved Very Happy .
Now I'll inquire how to get WhenChange.

Best regards,
Luigi
Re: DropList new When... action request [message #49418 is a reply to message #49416] Tue, 06 February 2018 20:49 Go to previous message
Oblivion is currently offline  Oblivion
Messages: 1094
Registered: August 2007
Senior Contributor
Hello Luigi,

In those cases, a simple course of action is to assign a unique/ordinary key (depending on the context) to the list elements (values), store the key of the active (or desired) item in a relevant variable and compare it to the next activated key everytime WhenAction is called.

Best regards.
Oblivion





[Updated on: Tue, 06 February 2018 20:51]

Report message to a moderator

Previous Topic: new released sample building error
Next Topic: FOUR State Option button
Goto Forum:
  


Current Time: Thu Jun 13 18:44:27 CEST 2024

Total time taken to generate the page: 0.02202 seconds