Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

variable in text box

Hi all

i have a variable that contains an expression, the output of that expression is a character...

now i want to show the output of that variable in text box but i want to calculate it over a particular value of the time dimension..

it is right to calculate it like this ? = only({$<year = {'2014'}>} $(variable))

thanks, Loris

5 Replies
ali_hijazi
Partner - Master II
Partner - Master II

what is the definition of $(variable)?

I can walk on water when it freezes
Not applicable
Author

if(($(mcc_rating_a)+$(mcc_rating_b)+$(mcc_rating_c)+$(mcc_rating_d)) >=9,

     'A',

     if(($(mcc_rating_a)+$(mcc_rating_b)+$(mcc_rating_c)+$(mcc_rating_d))  >=7,

          'B',

          'C'

     )

)

tresesco
MVP
MVP

PFA

sasikanth
Master
Master

hi

in Text box write like

=if(year='2014' , $(variable))

make sure that it shoud be a single value

Not applicable
Author

the expressionas i wrote it ( = only({ $<year = {'2014'}>} $(variable)) ) works...

my question is if it is a good way (through the only function) to achieve that result  or if there is a better (more efficent) way...

or when i have to use the only function and when not