on 05-16-2007 5:19 AM
Hi All,
In my SAPScript's main window many line items are coming. The output may appear on more than 1 page. I want to print the subtotal on each page(of the line items that are coming on that page), and I want to carry forward the previous page subtotal on the next page at top. This will happen on all pages...and in the end the grand total should appear.
I tried using SUMMING option...but don't have clarity on this. Plz help me out with a solution soon.
Thanks & Regards,
Niyati
Hi Niyati
If your lines items are comming on next page then summing the data and put it in a Footer of Table.The sub total will be displayed in a footer. T In the next page automatically total will be printed.
Reward points if it help.
Regards
Virendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Virendra,
The problem is:
I have used the summing command in the following way:
SUMMING &ITAB_TDS-BASAMT& INTO &ZTDS-BASE_AMT&
itab_tds is my internal table..and ZTDS is a transparent table(also defined in the tables stmt of the print program). When I debug, i find that the in ZTDS-BASE_AMT no value comes on executing the SUMMING command. Where am i wrong?
plz reply soon
Regards
Niyati
Hi,
In sapscript
/: Perform <b>Routine</b> in program <b>ProgramNAME</b>
/: using &ITAB_TDS-BASAMT&
/: CHANGING &ZTDS-BASE_AMT&
/:ENDPERFORM
In a custom program in se38
FORM <b>Routine</b> TABLES IT_INPUT STRUCTURE ITCSY
IT_OUTPUT STRUCTURE ITCSY.
DATA:
temp1 TYPE <b>of ITAB_TDS-BASAMT</b>,
temp2 TYPE <b>of &ZTDS-BASE_AMT&.</b>
FIELD-SYMBOLS: <fs_out_tab> TYPE itcsy.
READ TABLE IT_INPUT WITH index 1.
IF SY-SUBRC = 0.
MOVE IT_INPUT-VALUE TO temp1 .
ENDIF.
READ TABLE IT_INPUT WITH index 2.
IF SY-SUBRC = 0.
MOVE IT_INPUT-VALUE TO temp2 .
ENDIF.
temp2 = temp1 + temp2.
READ TABLE IT_OUTPUT ASSIGNING <fs_out_tab> INDEX 1.
IF sy-subrc EQ 0.
<fs_out_tab>-value = temp2.
ENDIF.
ENDFORM.
Regards,
Sooness.
User | Count |
---|---|
88 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
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.