on 09-11-2008 4:36 PM
Hello,
We have 3 custom condition types defined in pricing procedure. We need to add the values of all these 3 conditions and add into the last (i.e. 3rd condition).
Basically we want to collect the sum of all 3 conditions into the third condition value.
How can we use a condition value formula for it?
STEP Condition Type From To Subtotal AltCty
90 ZTST1 B
100 ZTST2 B
110 ZTST3 B 987 ?
But how can Formula 987 will collect the total of all these 3 conditions ZTST1, ZTST2 and ZTST3 ?
Thanks to advice,
Anand
Hi,
Good Day,
Please Try below code in your formula.
***form frm_kond_basis_987.
data : kwert_1 like xkomv-kwert .
data : it_komv like xkomv occurs 0 with header line.
refresh it_komv.
clear it_komv.
it_komv[] = xkomv[].
kwert_1 = 0.
loop at it_komv.
if it_komv-kschl = 'ZTST1' or it_komv-kschl = 'ZTST2'
or it_komv-kschl = 'ZTST3' .
kwert_1 = kwert_1 + it_komv-kwert.
endif.
endloop.
xkwert = kwert_1.
*****endform.
Best Regards,
KSK
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Don't you think you are bound to get ito a loop?
regds
Jude
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
6 | |
6 | |
4 | |
4 | |
3 | |
3 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.