Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
raviityou
Partner - Creator
Partner - Creator

Only one value can be selected from the listbox | Qlik Community

how to restrict  User   to selecting only one month at a time in list box
using month name and using  not always one selected  ?

Shared with Jive Anywhere

http://community.qlik.com/thread/51186
5 Replies
maxgro
MVP
MVP

maybe with a trigger on month field (OnSelect), something like

='(' & if(GetSelectedCount(Month)<>1, only({$1} Month),

GetFieldSelections( Month,'|' ) )

& ')'

to add the trigger go to

Settings -> Document Properties -> Triggers -> Field Event Triggers -> On Select - Add Actions ->

Add -> Select -> Select in Field

Not applicable

Hi Ravindra,

You need to first select the field name(eg: any month from the listbox)  then open list box properties then go to general tab and select "always one value selected" checkbox. Hope this helps.


Regards

raviityou
Partner - Creator
Partner - Creator
Author

Hi,

thanks for for solution but it is  not working as i need

i want at most one selection from list box .

i am using month name not month number

and user should not able to select more than one month at a time from that list box.

raviityou
Partner - Creator
Partner - Creator
Author

thanks for replay ,

but if i use always one selected then it will effect other chart also ,

the situation is user should not able to select month  name more than one at time,

and i can not use always one selected .

i have tried with

=if(GetAlternativeCount(Month)=0,Month,  Aggr(MaxString({<Month ={$(=FirstValue( Month, -Month))}>} Month), Month))

but if i select any month  then list box disappear.

raviityou
Partner - Creator
Partner - Creator
Author

hanks for replay ,

but if i use always one selected then it will effect other chart also ,

the situation is user should not able to select month  name more than one at time,

and i can not use always one selected .

i have tried with

=if(GetAlternativeCount(Month)=0,Month,  Aggr(MaxString({<Month ={$(=FirstValue( Month, -Month))}>} Month), Month))

but if i select any month  then list box disappear.