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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Re: Variable

Hi all,

I need to define a variable with two values as 'Yes' or 'No', since i need to use this variable in expressions for eg: If (MyVar='Yes',Salary*10,Salary).

how can it be done.

Thanks in advance.

BRegards,

Reena

1 Solution

Accepted Solutions
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Create an InputBox for your variable. On the Constraints tab select Predefined Values in Drop-Down. Enable the option Listed Values in the section Predefined Values. Enter Yes;No in the input field below the Listed Values check box.


talk is cheap, supply exceeds demand

View solution in original post

5 Replies
anbu1984
Master III
Master III

why do you need to set two values?

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Create an InputBox for your variable. On the Constraints tab select Predefined Values in Drop-Down. Enable the option Listed Values in the section Predefined Values. Enter Yes;No in the input field below the Listed Values check box.


talk is cheap, supply exceeds demand
Not applicable
Author

hi,

Actualy My application is for calculating the salary and bonus for employees.

so in order to calculate one bonus element,i require two values in input Box.

     As per the requirement, it should be a drop down with two values either Yes or no, if the user select 'Yes' for that particular employee the salary will be multiplied with 10%.like that.

Thanks

Not applicable
Author

Hi,

Thank You..it works,..

m_woolf
Master II
Master II

Gysbert,

Do you know if there is any way to set the "Predefined Values in Drop-Down" in a macro?