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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help in mandatory selection of Charts

Dear all,

I am having a chart with dimension as month,Year and Qtr and i am having a list box with same month,Year and Qtr as in chart dimension.

In Excel sheet i have kept the field and alled that label in Variable and that variable i am using in the dimension and list box it is woking fine,

when i am selecting month month as dimension appears and when i select year year as dimension comes.

But my problem is i want to show in the chart the message thatmandatory selection of list box.

i am using GetSelectedCount(Variable)=1, but it doesnt works as the fields are in variable.

Is there is any way to solve the problem.

Kindly please suggest

Regards,

Pranav

1 Solution

Accepted Solutions
erichshiino
Partner - Master
Partner - Master

maybe you could post at least the content of the variable...

... but you could use something like

if(isnull(variable), 0,1)

or if( len(variable)>0,1,0)

or if( isnull($(variable),0,1)

or in your list box, select on value, go to the object properties and check always one select value.

Hope it helps,

Erich

View solution in original post

5 Replies
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

   Will you please upload the qvw file

Thanks

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
erichshiino
Partner - Master
Partner - Master

maybe you could post at least the content of the variable...

... but you could use something like

if(isnull(variable), 0,1)

or if( len(variable)>0,1,0)

or if( isnull($(variable),0,1)

or in your list box, select on value, go to the object properties and check always one select value.

Hope it helps,

Erich

Not applicable
Author

Dear Erich,

Thanks for your reply and it works.

If i put if (len(Variable)>0,1,0) it works.

And Erich in list box  Check always one select value will noy work because in list box i have taken variable through expression so, the always select one check box is not enabled.

Can you please help me how to select any one value in list box with field in expression.

Kind Regards,

Pranav

erichshiino
Partner - Master
Partner - Master

I guess it should be the same.

Try to first select any value (only one), then you go back there and it should be enabled.

EDIT: Sorry... just tried and it doesn't work...

Not applicable
Author

Hi Erich,

No its not possible i have checked.

Is there any other way that we can select any one value with fields in expression.