on 08-06-2009 6:53 PM
Hi All;
I have a Transaction 'Z' that prints a Form Sapscritp. The user needs to download this form to a PC en .PDF format.
Could you tell me if there is a funtion or something do that ?
I know the standard program RSTXPDFT4. Even I created a transaction for this program. But the user need something
more direct .
Thanks
Kind regards
Marisol
Hi
[Converting SAP Script outputs to PDF file|https://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/49e15474-0e01-0010-9cba-e62df8244556&overridelayout=true]
Regards,
Sravanthi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi ,
You can use program RSTXSCRP
Or
you can use the T.code SE71 goto Utilities
in Utilities u find list---->in that u find down load to pc
then it wil down load.
Hope this will clear your doubt.
Or else you can refer to the follwoing links:
http://www.sap-basis-abap.com/sapac013.htm
http://www.sap-img.com/ts004.htm
Regards,
Dhanalakshmi L
Edited by: Dhanalakshmi Lakshumanan on Aug 7, 2009 12:25 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
To download the Form in PDF format, first you need to get the FORM output data in PDF format, but what we get from FORM output is OTF data.
data : lt_itcpp TYPE itcpp.
lt_itcpp-TDGETOTF = 'X'.
CALL FUNCTION 'CLOSE_FORM'
IMPORTING
result = itcpp " Information can be useful
TABLES
otfdata = lt_otfdata
EXCEPTIONS " eg dest, spool nr etc
unopened = 1.
from the above, U ill get the OTF data in lt_otfdata table.
CONSTANTS c_bin TYPE CHAR10 VALUE 'BIN'."unicode
CONSTANTS c_pdf TYPE char10 VALUE 'PDF'."unicode
DATA pdfdata_tab LIKE tline OCCURS 200.
DATA bindata_tab LIKE solisti1 OCCURS 200.
DATA filename_as_string TYPE string.
DATA filesize TYPE i.
DATA lv_lines TYPE i.
DESCRIBE TABLE lt_otfdata LINES lv_lines.
IF lv_lines <= 0.
pv_subrc = 4.
EXIT.
ENDIF.
IF destfile IS INITIAL.
pv_subrc = 4.
EXIT.
ENDIF.
FM converts the OTF data to PDF format
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
format = c_pdf
IMPORTING
bin_filesize = filesize
TABLES
otf = lt_otfdata
lines = pdfdata_tab
EXCEPTIONS
err_max_linewidth = 1
err_format = 2
err_conv_not_possible = 3
OTHERS = 4.
IF sy-subrc <> 0.
*-- Fehler beim Aufbereiten der PDF-Datei.
pv_subrc = 4.
exit.
ENDIF.
CALL FUNCTION 'QCE1_CONVERT'
TABLES
t_source_tab = pdfdata_tab
t_target_tab = bindata_tab
EXCEPTIONS
convert_not_possible = 1
OTHERS = 2.
IF sy-subrc <> 0.
*-- Fehler beim Aufbereiten der PDF-Datei.
pv_subrc = 4.
EXIT.
ENDIF.
Method to download the output in PDF
CALL METHOD cl_gui_frontend_services=>gui_download
EXPORTING
BIN_FILESIZE = filesize
filename = destfile
FILETYPE = c_bin
IMPORTING
FILELENGTH = filesize
changing
data_tab = bindata_tab.
Hope it helps!!
Rgds,
Pavan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Go to Transaction SP01.....Check the spool number and press the button "Print with Changed Parameters"........
There will be option to enter the Frontend Printer........select "Amyuni PDF Converter" from Dropdown.....
Now Press Print button....it will get a popup asking for Presentation server path...........
Give the path name and it will be stored as PDF format.....
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Just read the program to get hints, and then search the forum for more details
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
88 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
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.