Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone,
Could someone guide me how to use input box Variable Extension for the below scenario-
Firstly I have created 2 variables
I am using two Input Box -
Now I have written If condition for Invoice Amount column -
if(Sum([Invoice Amount])>= $(vMin_Invoice_Amt) and sum([Invoice Amount]) <= $(vMax_Invoice_Amt),sum([Invoice Amount]))
This filters accordingly the value entered in Input Boxs, But I want to display everything if there are no values entered in Input Box. Like show everything initially when users enters there input in the boxes it should filter accordingly.
Let me know if the is clear!
Thanks in advance
Not completely clear.. wont you have a default value for the input boxes. vMin_Invoice_Amt?
i am assuming you are asking about scenarios where one or both of the values are empty.
if so just add an empty condition to your if statement e.g. if(len(variable)=0....
let me know if i am missing something
Yes your right!
I wanted a logic where one or two values are empty.
Do i use it like this-
if(len(vMin_Invoice_Amt)=0 or Sum([Invoice Amount])>= $(vMin_Invoice_Amt) and sum([Invoice Amount]) <= $(vMax_Invoice_Amt),sum([Invoice Amount]))
Correct me if i am wrong!
you will need nested if loops
roughly
if (len($(vMin_Invoice_Amt))>0 and len($(vMax_Invoice_Amt))>0
, if(Sum([Invoice Amount])>= $(vMin_Invoice_Amt) and sum([Invoice Amount]) <= $(vMax_Invoice_Amt),sum([Invoice Amount]))
, if (len($(vMin_Invoice_Amt))=0 and len($(vMax_Invoice_Amt))>0,if(sum([Invoice Amount]) <= $(vMax_Invoice_Amt),sum([Invoice Amount]))
,....
)
)
)