I have a script that asks a user’s input for a number (saves it in variable X)
I would like the script to use this number and translate it to another variable Y (number) based on some range table.
if Variable X from 0 to 10 than the output will be variableY = 120
if Variable X from 11 to 20 than the output will be variableY =100
if Variable X from 21 to 30 … variableY = 90
and so on. about 10 ranges like that.
I dont want to build a lot of IF statements. whats the optimum way ?
As I have mentioned I am not very knowledgeable in KM.
so I have imported the downloaded makro. when I run it , it works.
but I have my own script with the user entry with additional parameters.
so how do I incorporate your macro inside my own macro ?
in my case, I dont what the Qty variable at all. I want it be calculated based on the TRIGGER.
so my X is the TRIGGER and the Y is Qty, to be later used down bellow in the macro.