Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
d_koti24
Creator II
Creator II

how to clear the field

Hi,

      i have one year list box ..in that 5 years are there like..2001 ,2002,2003,2004,2005.if i select any 2 years it display 2 years data.if i select more than 2 years ,i want clear that field.ex:2001,2002-2 years data,2001,2002,2003 -clear that field

Regards,

koti

1 Solution

Accepted Solutions
jagan
Luminary Alumni
Luminary Alumni

Hi,

Try like this

Set a Field Event trigger in Settings -> Document Properties -> Triggers -> Field Event Triggers -> Select Year Field -> On Select - Add Actions -> Select In Field -> Field = Year ->

Search String  =If(GetSelectedCount(Year) <= 2, '(' & Concat(Year, '|') & ')',  'dummy')

Hope this helps you.

Regards,

Jagan.

View solution in original post

6 Replies
jagan
Luminary Alumni
Luminary Alumni

Hi,

Try like this

Set a Field Event trigger in Settings -> Document Properties -> Triggers -> Field Event Triggers -> Select Year Field -> On Select - Add Actions -> Select In Field -> Field = Year ->

Search String  =If(GetSelectedCount(Year) <= 2, '(' & Concat(Year, '|') & ')',  'dummy')

Hope this helps you.

Regards,

Jagan.

jagan
Luminary Alumni
Luminary Alumni

Hi,

If you got the solution please close this thread by giving Correct Answer to the useful post.

Regards,

Jagan.

d_koti24
Creator II
Creator II
Author

it's working fine...but can u please explain briefly ....why ur using concat?

its_anandrjs

By using Concat you get single string like

( 2001 | 2002 | 2003 )

For searching this string requires thats why it is used.

Regards

Anand

jagan
Luminary Alumni
Luminary Alumni

Hi,

Concat() gives the values of a field in a concatenated format, for Select in field ( 2001 | 2002) we need to give Search string in this format, that is why I have used concat() to form this pattern.

Hope this helps you.  If you are clear please close this thread by giving correct and helpful answers to the useful posts.

Regards,

Jagan.

Not applicable

Hi,

PFA....

it's solve your query.

Thanks,

Ashok.