on 11-22-2010 1:53 PM
Hello SAP guru.
1. I have sapscript Z layout and I was required to convert and download this sapscript layout to PDF file. ( Not SPOOL !!!! )
2. To approach this I have used FM
CALL FUNCTION 'CLOSE_FORM'
TABLES
OTFDATA = DATAB[]
and then
CALL FUNCTION 'CONVERT_OTF'
EXPORTING
FORMAT = 'PDF'
IMPORTING
BIN_FILESIZE = BINFILESIZE
TABLES
otf = DATAB[]
lines = PDFTAB[]
and
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
BIN_FILESIZE = binfilesize
FILENAME = 'D:\myfile.pdf' ( here, instead of 😧 I download the file into network system - not local PC )
FILETYPE = 'BIN'.
the file has been created successfully, BUT
there are number of problems in created PDF file:
1. font differs from sapscripts font
2. data has been slided out of PDF form
3. lines slided out of PDF form
Please, advice how I can solve the problems.
Thanks,
regards,
Daniel
Give it a try with the code below for the transfer from your pdf-tab to the file
PERFORM download_w_ext(rstxpdft) TABLES pdf_tab
USING p_file
'.pdf'
'BIN'
binfilesize
cancel.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Tom and Aidan.
finally I have solved the problem.
I have used NEU standard layout as basis to create a spool and then I have used the programs that you adviced to convert and create PDF file.
Thanks a lot for your assistance.
Regards,
Daniel
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Daniel,
There will be some slight differences when converting to DF versus printed output. For print, the internal printer fonts are used. For PDF, the Adobe eader fonts are used. But from your description, it sounds like more than this.
Can you try the following test. Create a spool for print. Convert this created spool number to a PDF file via report RSTXPDFT4. Does the PDF created this way still look very different to the printed output?
Regards,
Aidan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Daniel,
If you turn the option 'SAVE_OTF_SPOOL' to 'On' via the report 'RSTXPDF3', then a spool should be created. See SAP note #924752 about this.
So you need to set this option and then create a new PDF. You then can see the created spool in SP01. Then convert this spool to PDF via RSTXPDFT4.
If this works thent he OTF data is ok and the problem is with your code to convert to PDF.
Regards,
Aidan
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
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.