cancel
Showing results for 
Search instead for 
Did you mean: 

Format not proper after converting OTF to PDF

Former Member
0 Kudos

Hi all,

I converted OTF to PDF (Using the function module 'SX_OBJECT_CONVERT_OTF_PDF') and sent it through an email. I observed that the format got changed at some places and is different from the actual output on the screen.

Could anyone let me know what could be wrong?

Thanks,

Raja

Accepted Solutions (0)

Answers (4)

Answers (4)

sridhar_k1
Active Contributor
0 Kudos

Output on the screen alway going to be little different from acutal output on paper or PDF, because different device types involved in the process. You need to adjust the the smartform, sapscript, or list to look ok in the PDF.

Regards

Sridhar

former_member206439
Contributor
0 Kudos

I am also getting the same issue.

I am using this FM for my Script and the font style gets different and indent is also wrong.

I tried all different FM but still have the same issue.

Former Member
0 Kudos

DATA : ITC TYPE ITCPO,

OTF LIKE TABLE OF ITCOO,

DOC LIKE TABLE OF DOCS,

TLINES LIKE TABLE OF TLINE,

BIN_FILESIZE TYPE I.

ITC-TDGETOTF = 'X'.

CALL FUNCTION 'CONVERT_OTF_2_PDF'

IMPORTING

BIN_FILESIZE = BIN_FILESIZE

TABLES

OTF = OTF

DOCTAB_ARCHIVE = DOC

LINES = TLINES.

CALL FUNCTION 'GUI_DOWNLOAD'

EXPORTING

BIN_FILESIZE = BIN_FILESIZE

FILENAME = 'C:\TESTPDF.PDF'

FILETYPE = 'BIN'

TABLES

DATA_TAB = tlines.

Now ur PDF file will be in PC with name TESTPDF.PDF.

Hope this will be useful to u.

With Regards,

Kalpanashri Rajendran.

Former Member
0 Kudos

try FM "CONVERT_OTF_2_PDF"

anversha_s
Active Contributor
0 Kudos

Hi,

pls use this FM.

FM is CONVERT_OTF.

CALL FUNCTION "CONVERT_OTF"

EXPORTING FORMAT = "PDF"

IMPORTING BIN_FILESIZE = FILE_LEN

TABLES OTF = OTFDATA

LINES = PDFDATA

EXCEPTIONS ERR_MAX_LINEWIDTH = 1

ERR_FORMAT = 2

ERR_CONV_NOT_POSSIBLE = 3

OTHERS = 4.

also check sample programs

RSTXPDF4/5.

rgds

anver

if hlped pls mark points

Former Member
0 Kudos

Anversha,

Thanks for your immediate response.

I tried with this FM too. But same problem.

Raja