Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Problem with current selection box

Hi,

I Have a requirement where  i have to use action->to select field->and in place of search string i have to use a variable.

This works fine as expected ! but the values in current selection box is showing as below.

("india"|"usa"|"uk")

instead of showing india,usa,uk

Attaching a sample application,can someone please provide me the solution to this problem.

Thanks,

Sandeep

13 Replies
chinnuchinni
Creator III
Creator III

just modify your your variable value as :

=GetFieldSelections(Country)

Anonymous
Not applicable
Author

Hi Praveen,

Thanks for the replay.

In real, i have field values with spaces your solution is only working without spaces .

Please look into the new attached file.

Thanks,

Sandeep

chinnuchinni
Creator III
Creator III

you can use in script.

trim(Country) as Country

Anonymous
Not applicable
Author

this does not solve my problem,

1)i cant trim the field values

2)search string in actions is not working if there are spaces in field values that is why i have used the below expression

='('&chr(34)& GetFieldSelections(Country,chr(34)&'|'&chr(34)  ) &chr(34)&')'

Thanks

tresesco
MVP
MVP

Try with chr(39), instead of chr(34)

Anonymous
Not applicable
Author

Id Country len(Country)
0
1India5
2USA3
3UK2
4Australia9
5Brazil6

I still do not understand your need, but in the field Country no have spaces...

The idea of Praveen is very good, solve in the script!

Anonymous
Not applicable
Author

tried with 39 its not working

Anonymous
Not applicable
Author

Hi Guy,

thanks for helping out.

Let me put it in a simple way,i need a button by clicking it USA new,UK new and India new should be selected in country field

and current selection box should show USA new,UK new,India new

insted of ("USA new","UK new","india new").


Thanks

Anonymous
Not applicable
Author

Hi Guy,

thanks for helping out.

Let me put it in a simple way,i need a button by clicking it USA new,UK new and India new should be selected in country field

and current selection box should show USA new,UK new,India new

insted of ("USA new","UK new","india new").