on 06-29-2008 6:48 AM
hi,
I have one internal table with 5 columns,(register id, business area, amount1, amount2,total) , now i want to pass this data to SAP script main window table, here is the condition ,if for the particular business area there is no data (amount and total are equal to 0.) that business area row is not displayed in table, that means in table rows are dynamic.And after displaying all rows i want to display totals row.
These all rows are dispaly in lines means , header.|
-
| -
row1. |
-
|----
row2 |
-
|----
totals row
-
I tried to put the IF condition in text editor, but it is not working.
Can any one please let me know the solution.
Thanks in advance.
Hello,
First, in the driver program just before you call this window you need to delete all the entries from the internal table where amount and total are equal to 0.This will give you entries which are required to be populated in the script. You can also use IF statement like
IF &AMOUNT& NE 0 OR &TOTAL& NE 0.
...
ENDIF.
In case of rows, you can use LOOP-ENDLOOP.
Hope this solves your query.
Reward helpful answers
Regards,
Subodh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
In your text editor use the if command like this
if &amount& ne 0 or &total& ne 0
&amount&,,&total&..... so on
&sapscript-counter_01(+0)&
endif.
&sapscript-counter_01& is a counter variable we can have upto 10 starting from 0 to 9.
after displaying all the records you can display the total number of records using
&sapscript-counter_01&
This would solve your issue.
reward points if useful
regards
padma
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.