01-14-2015 6:51 AM
Hi all,
I have developed a classical report which display Customers FI ledger. I have made the display such that each customers data gets printed on a new page. Now i wont a spool number to be created for each page so that , it can be converted to pdf and sent as a attachment in a mail to the respective customer.
Can you please help me in creating the spool number for each page. ?
Thanks
Neha
01-14-2015 7:06 AM
This is not possible. A new spool number means a new spool.
Split the spool into several ones.
See the following code snippet::
NEW-PAGE PRINT ON NO DIALOG NO-HEADING NO-TITLE
DESTINATION lv_printer
LINE-SIZE 80
LINE-COUNT 65
IMMEDIATELY space
KEEP IN SPOOL 'X'.
Regards,
Ulrich
01-14-2015 9:21 AM
Hi,
Thanks for your response.
But may i know how to split the spool number ?
01-14-2015 9:42 AM
The following example creates 2 spools:
NEW-PAGE PRINT ON NO DIALOG NO-HEADING NO-TITLE
DESTINATION lv_printer
LINE-SIZE 80
LINE-COUNT 65
IMMEDIATELY space
KEEP IN SPOOL 'X'.
write: 'This is the content of page 1'.
NEW-PAGE PRINT OFF.
* read spool number from SY-SPONO
NEW-PAGE PRINT ON NO DIALOG NO-HEADING NO-TITLE
DESTINATION lv_printer
LINE-SIZE 80
LINE-COUNT 65
IMMEDIATELY space
KEEP IN SPOOL 'X'.
write: 'This is the content of page 2'.
NEW-PAGE PRINT OFF.
* read spool number from SY-SPONO