09-21-2007 2:09 AM
Hi,
I have a problem in end of page event.
while if the value changes for a particular field of internal table , new new page should trigger with header and footer which are in top and end of page event.
while in loop of internal table.
i have given like at new field.
new-page.
endat.
first its working fine but when field changes its not displaying end of page values for new page.
but only at the last. its displaying.
Thansks,
Vijay
09-21-2007 2:19 AM
Instead of writing the new-page in at new field try it in
AT END OF field.
new-page.
END AT
09-21-2007 2:19 AM
Instead of writing the new-page in at new field try it in
AT END OF field.
new-page.
END AT
09-21-2007 2:50 AM
09-21-2007 3:01 AM
You might have to trigger end of page explicitly. In program, try this.
AT NEW XXX
new-page.
ENDAT.
AT END of XXX.
if sy-linct >= SY-CUROW.
skip (sy-linct - current line no) records.
This will trigger end of page.
ENDAT.
09-21-2007 4:35 AM
just see this SAP help documentation of new-page.
NEW-PAGE.
Extras:
1. ... NO-TITLE
2. ... WITH-TITLE
3. ... NO-HEADING
4. ... WITH-HEADING
5. ... LINE-COUNT lin
6. ... LINE-SIZE col
7. ... NO-TOPOFPAGE
8. ... PRINT ON ...
9. ... PRINT ON ... (obsolete additions)
10. ... PRINT OFF
Effect
Starts a new page during list processing.
Terminates the current page and continues output on a new page.
Notes
NEW-PAGE does not generate blank pages, it ignores pages containing no output.
NEW-PAGE increments the page counter (the system field SY-PAGNO).
<b>The event END-OF-PAGE is not processed.</b>
To start a new page depending on the number of unused lines remaining on the current page, use the RESERVE statement.
so try to use reserve statement( if it suits you ).
regards
shiba dutta