01-29-2008 12:57 PM
In a clasic reportthe requirement is that at every AT_NEW statement ,the related matter shld be printed on new page.
for eg. if for div. from 1 to 5, for each div. the related matter shld be printed on new page. thus report consists of at least 5 pages.
Thanks & Regards,
Gowd.
01-30-2008 6:29 AM
Hi,
after AT-NEW statment use skip lines command . Skip maximum number of lines .
Suppose if you have defined 32 lines per page then you can use
skip 32 lines .
No need to use complex logic.
Reward points if useful
Regards,
Nageswar
01-29-2008 12:59 PM
Pls look this.
hope it will help you.
Reward if help.
All this AT NEW, AT FIRST, AT END OF and AT LAST are called control break statements of Internal tables and are used to calculate the TOTALS based on sertain key fields in that internal table
FIrst to use these statements the ITAB has to be sorted by the key fields on whcih you need the SUM of the fields.
Some time you will get * when mopving data from this int table to other table using these commands
so you have to use
READ TABLE ITAB INDEX SY-TABIX in AT..ENDAT..if you are using other fields between them
DATA: sflight_tab TYPE SORTED TABLE OF sflight
WITH UNIQUE KEY carrid connid fldate,
sflight_wa LIKE LINE OF sflight_tab.
SELECT *
FROM sflight
INTO TABLE sflight_tab.
LOOP AT sflight_tab INTO sflight_wa.
AT NEW connid.
WRITE: / sflight_wa-carrid,
sflight_wa-connid.
ULINE.
ENDAT.
WRITE: / sflight_wa-fldate,
sflight_wa-seatsocc.
AT END OF connid.
SUM.
ULINE.
WRITE: / 'Sum',
sflight_wa-seatsocc UNDER sflight_wa-seatsocc.
SKIP.
ENDAT.
AT END OF carrid.
SUM.
ULINE.
WRITE: / 'Carrier Sum',
sflight_wa-seatsocc UNDER sflight_wa-seatsocc.
NEW-PAGE.
ENDAT.
AT LAST.
SUM.
WRITE: / 'Overall Sum',
sflight_wa-seatsocc UNDER sflight_wa-seatsocc.
ENDAT.
ENDLOOP.
01-29-2008 1:00 PM
Hi,
use command new-page in at new
for more info
http://www.sts.tu-harburg.de/teaching/sap_r3/ABAP4/new_pa01.htm
regards
Shiva
01-29-2008 1:00 PM
YOU SHOULD USE
AT NEW DIV.
new-page.
then whatver filds you wanna write.
endat.
but remember to take all fields that you want to print in separate variables because "at new " wont recognize them
it will recognize new variables.
reawrd if helpful
keep rockin
vivek
01-29-2008 1:01 PM
Hi Muneshwar,
You can use NEW-PAGE command in your AT NEW event.which will trigger new page for every new delivery.
This might help you.
Regards,
kalyan.
01-29-2008 1:02 PM
01-30-2008 6:22 AM
01-30-2008 6:29 AM
Hi,
after AT-NEW statment use skip lines command . Skip maximum number of lines .
Suppose if you have defined 32 lines per page then you can use
skip 32 lines .
No need to use complex logic.
Reward points if useful
Regards,
Nageswar