Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Add/take-away values

Hi everyone,

I have a list of orders by company. I want to be able to select some orders to exclude, show the excluded values in another list box, and then be able to choose some of those excluded orders to add back to the selection.

E.g.

 

OrdersExcluded
A
B
C
D

Select C+D to exclude

 

OrdersExcluded
AC
BD

Then select D to include again, but leave C out:

 

OrdersExcluded
AC
B
D
1 Solution

Accepted Solutions
MK_QSL
MVP
MVP

For Selected

=IF(GetFieldSelections(Orders) > 0 ,Aggr(Orders,Orders))

For Not Selected

=aggr(only({1-$} Orders),Orders)

View solution in original post

6 Replies
MK_QSL
MVP
MVP

For selected use below in List Box expression

=IF(GetFieldSelections(Orders) > 0 ,Aggr(Orders,Orders))

Not applicable
Author

Thanks Manish. Any idea about the rest?

Not applicable
Author

Does anyone else have an idea for this? Or is it a capability not native to Qlikview?

MK_QSL
MVP
MVP

For Selected

=IF(GetFieldSelections(Orders) > 0 ,Aggr(Orders,Orders))

For Not Selected

=aggr(only({1-$} Orders),Orders)

Anonymous
Not applicable
Author

See if this helps...

Not applicable
Author

Thank you so much. Both work great. But it's a shame that to add excluded values back to the selection, I can't just ctrl+click that calculated list box - if I do, it erases my current selections and replaces them with the new one. Instead, I have to ctrl+click the original list box. This is fine, but 2 list boxes would be better than three...

Anyway, thanks!