Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

To Select Blank Value Using Trigger

Hi,

I have to select a set of values(including blank) in a particular field as default while leaving a sheet.

And I am using the following triggers

Select in Field:

Field: FIELD

Search String: only({<FIELD={"=len(FIELD)=0"} >}FIELD)

Toggle Select:

Field: FIELD

Search String: (Value1|Value2)

This works only if there is no selection on that FIELD. If there is any other selections, it is not working. Even I have tried 'Clear All Field' Trigger. But doesn't works.

Please help to find a solution.

Thanks & Regards,

Vinitha Mano R.

10 Replies
Not applicable
Author

Are you really trying to clear the selections or select all the values in that field? Try changing the search string as *

sundarakumar
Specialist II
Specialist II

Hi Vinitha,

R u trying to do something ike document chaining?

Plese explain "doesn't work"...

-sundar

maxgro
MVP
MVP

if I understand I think you coulduse a trigger like that

select in field        

field          field

expression

=if(GetSelectedCount(field)>0,

'(' & concat(if(len(trim(field))>0, '"' & field & '"' ), '|')  & '|""' &  ')' ,

'('  & '""' &  ')'

)

the idea is to create a search expression with the selected values (concat) and then add at the end the blank value

("firstselected"|"secondselected"|...........|"lastselected"|"")

see attachment

Not applicable
Author

Hi,

Since the trigger with condition "only({<FIELD={"=len(FIELD)=0"} >}FIELD)" is working if there is no selections on that field, I have tried to apply 'Clear field' trigger before applying "select in Field" trigger.

But even then the blank value is not selected if I leave the page but the other 2 values which I have mentioned in 'Toggle Select' trigger is selected.

Now I would like to select the 2 values along with the blank value when I leave the page.

Kindly help.

Thanks & Regards,

Vinitha Mano R.

Not applicable
Author

Can you attach a sample because I don't know the 2 values you are trying to select when you leave the page.

Not applicable
Author

find below an example where I could select two values along with the blank

("b"|"f"|"")

Try it after changing your intended values

Not applicable
Author

Hi,

I have attached the sample.

Kindly help.

Thanks & Regards,

Vinitha Mano R.

Not applicable
Author

Thanks for the sample.

Please check the triggers in sheet properties onActivateSheet for the selection when entering the sheet and OnLeaveSheet for the selection when leaving the sheet.

Regards,

Sajeevan

Not applicable
Author

Hi,

Thank you for your help. It works fine.

Thanks & Regards,

Vinitha Mano R.