on 06-16-2009 1:56 PM
carry forward amount into next pages in scripts and also i want to print all pages total in the last page .
example i have 5 pages in 5th page means last page i am only displaying company address and text in 4th page last i have to display 4 pages totals .
First page i have to display first page line items totals in the last.
Second page top i have to display first page totals and second page line items and its totals in the last.
3rd page same as above second page.
4th page i have to display top 3rd page totals and end of the page i have to display 4 pages totals.
5th page company information.
please suggest me logic.
Hi Subba rao,
Refer this [Wiki|https://www.sdn.sap.com/irj/scn/wiki?path=/display/abap/displayingspecificnumberofrecordsperpage.] for your requirement
Regards,
Sravanthi
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 main window define the carry forward and totals as....
(this below statement should be written at the top before ant data elements....)
/: SUMMING &FS_FLIGHT-PRICE& INTO &W_SUM&
NOW UNDER A DATA ELEMENT LIKE
/E CARRY
/: IF &PAGE& NE 1.
CARRY FORWARD AMOUNT : &W_SUM&
/: ENDIF.
/E GRAND_TOTAL
GRAND TOTAL : &W_SUM&
after you have done this ....
in the driver program call THE WRITE FORM in this way in open form and close form.......
form main_window .
loop at t_flight into fs_flight.
call function 'WRITE_FORM'
exporting
element = 'CARRY'
window = 'MAIN'
exceptions
element = 1
function = 2
type = 3
unopened = 4
unstarted = 5
window = 6
bad_pageformat_for_print = 7
spool_error = 8
codepage = 9
others = 10.
This statement is used to display the grand total for the last page
at last.
call function 'WRITE_FORM'
exporting
element = 'GRAND_TOTAL'
window = 'MAIN'
exceptions
element = 1
function = 2
type = 3
unopened = 4
unstarted = 5
window = 6
bad_pageformat_for_print = 7
spool_error = 8
codepage = 9
others = 10.
exit.
endat.
ENDLOOP.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Use 2 Different variables,1 for each page total e.g X & other for grand total to be displayed on last page e.g. Y.
Use Variable 'X' to hold total for each page & refresh it at new page.
Regards,
Yogendra.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
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.