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: 
dsharmaqv
Creator III
Creator III

Enable Condition For Expression

Hi

I have to hide one expression out of 5 expression in straight table when ever a user perform some selection from the list object Business_L1 Or Business_L2

I tried below condition but its not working

GetSelectedCount([Sub - Business Line])<=0  or GetSelectedCount([Business Line L1])<=0

If I use only one condition then its working fine

GetSelectedCount([Sub - Business Line])<=0

Can some help me out with this

Many thanks in advance

1 Solution

Accepted Solutions
sunny_talwar

Not sure I understand the point of using <= here? Count of selection can never be less than 0.

Also, do you need both to be not selected? May be use and

GetSelectedCount([Sub - Business Line])=0  and GetSelectedCount([Business Line L1])=0

View solution in original post

3 Replies
sunny_talwar

Not sure I understand the point of using <= here? Count of selection can never be less than 0.

Also, do you need both to be not selected? May be use and

GetSelectedCount([Sub - Business Line])=0  and GetSelectedCount([Business Line L1])=0

jonathandienst
Partner - Champion III
Partner - Champion III

There is nothing syntactically wrong with the Or statement (assuming the field names are correct); this condition will evaluate to true if there is no selection in either or both of the fields. Perhaps you need an AND rather than an OR?

BTW - GetSelectedCount will never return a negative, so you can just test against 0 to see if there is a selection.

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
dsharmaqv
Creator III
Creator III
Author

thanks sunny logical error i sholud have used AND