webapplication how get listbox selected item(s) value

hi there


in web application i filled listbox values (multi select enabled)  with aggregate and i want to get listbox selected items value anyone know how can i do it? i want to know which item(s) selected by user, as i understand outsystems listbox do not have selected item property or event


regards,

omid ghanbari

Solution

Hi,

The list you define has source needs to have a field which is a boolean and you configure that field has "Selection Attribute". That you just need to loop through the ListBox List and use ListBox1.List.Current.<source>.<selectionAttribute> to check if that element was selected.

Regards,

Marcelo

 

Solution

Marcelo Ferreira wrote:

Hi,

The list you define has source needs to have a field which is a boolean and you configure that field has "Selection Attribute". That you just need to loop through the ListBox List and use ListBox1.List.Current.<source>.<selectionAttribute> to check if that element was selected.

Regards,

Marcelo

 

hi,

thank you very much i can resolve my problem with your help

but there is a strange thing: 

when we are using tablerecords with checkbox for selection connected to Aggregate: if you add Boolean calculated column to aggregate to main source or add Boolean structure as second source both of them works.

 but when you are using list box connected to aggregate you can not add Boolean field to main source it does not work and you have to add Boolean structure as second source it works !!!

regards,

omid ghanbari


Hi ,

Glad you were able o find the solution :)

Regards,

Marcelo