on 05-13-2010 4:31 PM
Hi,
I am facing problem with multiple conditions for a node.
My requirement is that node should be displayed only
a) Amt is greater than zero
b) Invoice type NE 'IV' and company code NE '001'.
The condition fails in any of one scenarios ( tried with OR and AND combinations).
Any advise or alternative solutions would be helpful .
Thanks
Regards
Reddy
Hi,
It wud be better to create a W_flag variable in Global definitions TYPE FLAG..
Then create a Code node (Create -> Flow Logic -> Program Logics) .. keep this code node just before your existing node...
Put w_flag. w_amount , w_invoice_type and w_company_code in the Input Parameters. and Put w_flag in out parameters as well...
Now code like this as below in the editor..
if w_amount > '0'.
if w_invoice_type ne 'IV' and w_company_code ne '001'.
w_flag = 'X'.
endif.
endif.
Now in your existing node you can use this Flag as a condition .. So put this in Condition tab... as below:
Field name relational operator Com value
W_FLAG = 'X'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Thanks. Resolved with your inputs.
Regards
Reddy
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Well, that sounds like three simple chained AND conditions; I'm not sure why it wouldn't work. You can debug it in the generated smartform code if necessary. However, for complex conditions, you can always create a global variable flag (type XFELD) and use a programming node to set the value of the variable prior to your other node. Then you simply need to check the value of the flag instead of checking all of the other conditions for your node.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
9 | |
9 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.