Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

deniscamh
Contributor

Display measure only when no selection made

Hello all,

I have a combo chart the represents number of donors and renewal rate by fiscal year.

The renewal rate calculation is: Current Year Active Donors / Total Donors from Prior Year.

When Total Donors from Prior Year is a hard coded field I created in script.

What I need is when there is no selection made by user the chart will display Number of Donors and Renewal Rate but when at least one selection made the chart would display Number of Donors only without Renewal Rate

Please any suggestions?

Before selection

numofDonors.JPG

After Selection made

numofDinors2.JPG

Thanks

1 Solution

Accepted Solutions
mato32188
Contributor III

Re: Display measure only when no selection made

Hi Denis,

try this:

Expression:

if(count(GetCurrentSelections()>0), YOUREXPRESSIONwhenSelectionIsMade, YOUREXPRESSIONwhenNoSelectionIsMade)


YOUREXPRESSION should be 0 and then just do not show zero values.


It is dirty solution, but it should work.

BR

Martin

2 Replies
mato32188
Contributor III

Re: Display measure only when no selection made

Hi Denis,

try this:

Expression:

if(count(GetCurrentSelections()>0), YOUREXPRESSIONwhenSelectionIsMade, YOUREXPRESSIONwhenNoSelectionIsMade)


YOUREXPRESSION should be 0 and then just do not show zero values.


It is dirty solution, but it should work.

BR

Martin

deniscamh
Contributor

Re: Display measure only when no selection made

Thanks Martin,

That works

Community Browser