Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

how to put multiple if statements in app script and rename them ???

hi all,

Please can someone help me with the below isse,

I have attached a sample file where a small scrip is present.Here you can see an if statement which has been renamed as 'A'.NOw I want to include 3 more such if conditions and rename them differently,but I am not able to do so.please can anyone help me out to resolve this issue???

...

if( [Fin Base Index Price]<= [Strike Price],-1*(xoptionpremium),((-1*(xoptionpremium)+ ([Fin Base Index Price]-[Strike Price]) )) as A,

if( [Fin Base Index Price]<= [Strike Price],+1*(xoptionpremium),((+1*(xoptionpremium)_ ([Fin Base Index Price]-[Strike Price]) )) as B,

if( [Fin Base Index Price]<= [Strike Price],((-1*(xoptionpremium)+ ([Fin Base Index Price]-[Strike Price]) )-1*(xoptionpremium) )) as C,

.......

from

.....

I want the script to be as below,but as I give my second if statement the 'from ' does not work and the rest as well.

3 Replies
Not applicable
Author

What is the purpose? What we try to do?

Not applicable
Author

hi sahana,

it seems your QVW has many tabs n charts so in which tab and chart you want this expression to be corrected ??

regards

harshal sonone

Not applicable
Author

hi all,

thanks for your interest and response.There was a syntax error with brackets... its resolved now..

thanks,

Sahana