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

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

conditional Enable and Disable of expression

Hi All,

I have requirement as follows.

in my application i m using a straight table with expressions. These expressions are the calculations for allowances for employees. So i am having a list box with all the allowances Name.

Now the requirement is.

when user select an allowance from the list box ,then only the particular expression should gt enabled or show ,all others should be hidden. at a time user can select more than 1 expression also. so accordingly it should display..

How can i achieve the same?please suggest..

Thanks..

10 Replies
MK_QSL
MVP
MVP

Go to Expression Tab

Select Your Expression

Tick Conditional

Write Below as a conditional expression

=GetSelectedCount([allowances Name])>0

jagan
Partner - Champion III
Partner - Champion III

Hi,

Check this link

Adhoc reporting in Qlikview


Hope it helps you.


Regards,

Jagan.

avinashelite

Hi Reena,

How many allowance type you have??

deepakqlikview_123
Specialist
Specialist

Anonymous
Not applicable
Author

Hi,

you should pass the allowance in the dimension then in the expression check enable the conditional

then put = getselectedcount(allowance)>0 .

That is the one way or you can make Adhoc report as jagan marked.

Thanks

jagan
Partner - Champion III
Partner - Champion III

Hi,

Use this expression as conditional expression

=SubStringCount('|' & Concat(distinct Allowance, '|') & '|', '|Allowance1|') -- For Allowance1

=SubStringCount('|' & Concat(distinct Allowance, '|') & '|', '|Allowance2|') -- For Allowance2

Regards,

Jagan.

Not applicable
Author

Hi..

Thanks for your reply..

But i have more than 160 allowances as expressions,each with different rules. so for each allowance selection i need to enable and disable.

Not applicable
Author

Hi Reena,

in the conditional of each expression give conditional like this..

if(match ( only ({1} [Allowance]), $ (= cancat (distinct chr(39) & [Allowance] & chr(39) , ' , ' ) ) ) , 1, 0 )

Regards,

Vivek

Not applicable
Author

Hii...

Thanks Jagan... its working..

bt while using this condition without any selection it will show all the expressions i think.

In my case if there is no selection then dimensions it should display and there is one expression without condition that also it should display. Rest all expressions it should be hidden.

Thanks..