‎2006 Dec 06 6:07 AM
hi all,
i have the scenario to convert Purchase Order into PDF Format.
that PDF format should be stored in app server.
please help me to solve this problem.
Your help is greatly appreciated.
‎2006 Dec 06 6:13 AM
PO as SMART Form and mail as PDF
How to convert smartform output to PDF and mailing them
‎2006 Dec 06 6:09 AM
Hi,
You can use RSTXPDFT4 to convert the report into pdf format..
‎2006 Dec 06 6:13 AM
PO as SMART Form and mail as PDF
How to convert smartform output to PDF and mailing them
‎2006 Dec 06 6:16 AM
HI ,
u can get idea on looking this code.
data: ctrlparams type ssfctrlop.
data: fm_name type rs38l_fnam,
fname type string value 'c:\reportpdf.pdf',
bin_size type i,
joboutput type ssfcrescl,
it_result like table of itcoo,"JOBOUTPUT-OTFDATA
otf like table of itcoo,
doc like table of docs,
tlines like table of tline.
data: begin of struct occurs 0.
include structure spfli.
data: end of struct.
data: itab like table of struct with header line.
call function 'SSF_FUNCTION_MODULE_NAME'
exporting
formname = 'ZSIVA_SMARTFORMS'
FORMNAME = 'SF_TOTALS'
importing
fm_name = fm_name
.
if sy-subrc <> 0.
endif.
ctrlparams-getotf = 'X'.
call function fm_name
exporting
control_parameters = ctrlparams
importing
job_output_info = joboutput
tables
itab = itab.
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5.
*
*IF SY-SUBRC <> 0.
*
*ENDIF.
call function 'CONVERT_OTF_2_PDF'
importing
bin_filesize = bin_size
tables
otf = joboutput-otfdata[] "otf
\
doctab_archive = doc
lines = tlines
.
call function 'GUI_DOWNLOAD'
exporting
bin_filesize = bin_size
filename = 'C:\siva\test.pdf'
filetype = 'BIN'
tables
data_tab = tlines.
* Open PDF
data: program like soxpc-path.
call function 'SO_PROGNAME_GET_WITH_PATH'
exporting
doctype = 'PDF'
importing
pathname = program
exceptions
path_not_found = 1
program_not_found = 2
no_batch = 3
x_error = 4
others = 5.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
*
call function 'WS_EXECUTE'
exporting
commandline = 'C:\siva\test.pdf'
program = program
exceptions
frontend_error = 1
no_batch = 2
prog_not_found = 3
illegal_option = 4
gui_refuse_execute = 5
others = 6.
if sy-subrc <> 0.
message id sy-msgid type sy-msgty number sy-msgno
with sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
endif.
regards,
shan
‎2006 Dec 06 6:17 AM
Dear anburaja,
SAP have created a standard program RSTXPDFT4 to convert your Sapscripts spools into a PDF format.
Specify the spool number and you will be able to download the sapscripts spool into your local harddisk.
It look exactly like what you see during a spool display.
Please note that it is not restricted to sapsciprts spool only. Any reports in the spool can be converted using the program 'RSTXPDFT4'.
‎2006 Dec 06 8:27 AM
‎2006 Dec 06 8:48 AM
‎2006 Dec 06 8:17 AM
‎2006 Dec 06 11:38 AM
hi all,
some of the cases PO is not holding messages.
it means no messages for PO's.
that scenario dump occurs while i'm using ECP_PDF_DISPLAY fm...
how can i handle that situation?
creating message( using BDC for ME22N ) is not working in background.
it display errors like.
Unable to initialise ABAP Control Framework ...
Unable to initialise ABAP Control Framework ...
Control Framework: Fatal error - GUI cannot be reached
Runtime error RAISE_EXCEPTION has occurred
Message was not created