Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

NOT selection in AND-mode field

Assume you have a AND-mode listbox with values A,B,C,D

With a ACTION (behind a button) we want to make an automatic selection in this listbox :

  1. We create the button and select the properties
  2. in the ACTIONS tab we add the action -> SELECT IN FIELD
  3. FIELD = the AND-mode listbox

So far so good, but then we have to fill in the SEARCH STRING.

  • If we want to make the selection A AND B, then our search string is : (A|B)
  • But what is the search string if we want to select A AND NOT B????
6 Replies
vgutkovsky
Master II
Master II

Sven, take a look at an alternate method of doing AND/NOT selections, which I discuss in the last comment to this post: http://community.qlik.com/thread/62060.

Vlad

Not applicable
Author

Hi Vlad

I already checed out that post and gave me good insight in another problem

But here i really need to automate the selection i make in a Listbox and unfortunatly it's an AND-mode list box where we need to make NOT selections

Andrea_Ghirardello

Try to use regular expressions:

How to use regular expressions

In order to exclude some values (say NOT USA), use:

^((?!USA).)*$

Not applicable
Author

I am not trying to exclude some values

i am trying to make a NOT selection in an AND-mode box (see attachment)

Untitled.png

vgutkovsky
Master II
Master II

Sven, there are 2 list boxes in my solution: AND and NOT. Since they're separate, all you have to do is trigger a selection in the NOT list box.

Vlad

hugmarcel
Specialist
Specialist

it is not possible to set the NOT-state via Action button.

You have to use the SetAnalysis-Way, or do it manually in the listbox.

Marcel