Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Convert to PDF Format.............

Former Member
0 Kudos

Dear Experts,

I made a ALV report and provided one option to convert into PDF format.

How to convert that ALV report into PDF format ? How to pass spool request ?

Pl. give some idea with example.

Yusuf

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi u can do a select in table TSP01and fetch RQIDENT which stores spoll id and call the functin module which will give you the output..!

Thanx,

Navin.

9 REPLIES 9

GauthamV
Active Contributor
0 Kudos

hi,

USE this standard program.

RSTXPDF4.

vinod_vemuru2
Active Contributor
0 Kudos

Hi Yusuf,

U can submit the report RSTXPDFT4 for converting SPOOL to PDF format. U have to pass Spool number and download path.

Try executing this report in SE38 and see if it helps u.

Thanks,

Vinod.

0 Kudos

Hi Vinod,

But how to pass spool request ? when i run ALV report it creates spool and that spool i want to pass within ALV program itself.

Yusuf

0 Kudos

Hi,

Put below piece of code. But it will give a popup for asking file name. Here u have to provide the file name to where the file should be downloaded.


DATA: i_selection TYPE TABLE OF RSPARAMS,
      wa_selection TYPE RSPARAMS.

wa_selection-selname = 'SPOOLNO'.
wa_selection-kind = 'P'.
wa_selection-low = '29521'.
APPEND wa_selection TO i_selection.

SUBMIT RSTXPDFT4 WITH SELECTION-TABLE i_selection.

Thanks,

Vinod.

Former Member
0 Kudos

Hi ,

U can use the function module ' CONVERT_ABAPSPOOLJOB_2_PDF' to convert alv spool output to pdf..!

Thanx ,

navin

Former Member
0 Kudos

Hi u can do a select in table TSP01and fetch RQIDENT which stores spoll id and call the functin module which will give you the output..!

Thanx,

Navin.

0 Kudos

HI Navin,

How to get spool number from tsp01 table ? There are many spool in that table. How to know this spool is for this report ?

Yusuf

0 Kudos

Hi Yusuf,

If you go to SP02 u can see every spool which is generated has a tittle..

Similarly use a similar select as described below to get the Spool no:

SELECT rqident

rqowner

rqtitle FROM tsp01

INTO TABLE l_i_spool

WHERE ( rqowner EQ sy-uname ) AND

( rqtitle EQ 'Z_TITTLE' ).

Just supply all the parameters to the function module and your work should be done...

Hope this solves your problem.

Thanx,

Navin.

Former Member
0 Kudos

Run RSTXPDF4 program