Skip to Content
0
Former Member
Dec 01, 2006 at 12:59 PM

Smartform to PDF and e_mail? Urgent

24 Views

hi all,

i am able to convert smartform to pdf and download the pdf onto desktop but not able to send it as attachment thru email.

CALL FUNCTION 'CONVERT_OTF_2_PDF'

EXPORTING

use_otf_mc_cmd = 'X'

IMPORTING

bin_filesize = v_len_in

TABLES

otf = i_otf[]

doctab_archive = lt_doctab

lines = <b>i_tline</b>

EXCEPTIONS

err_conv_not_possible = 1

err_otf_mc_noendmarker = 2

OTHERS = 3.

PERFORM doconv TABLES i_tline objbin.

.......

FORM doconv TABLES

mypdf STRUCTURE tline

outbin STRUCTURE solisti1.

*----


Data

DATA : pos TYPE i.

DATA : len TYPE i.

*----


Loop And Put Data

LOOP AT mypdf.

pos = 255 - len.

IF pos > 134. "length of pdf_table

pos = 134.

ENDIF.

outbin+len = mypdf(pos).

len = len + pos.

IF len = 255. "length of out (contents_bin)

APPEND outbin.

CLEAR: outbin, len.

IF pos < 134.

outbin = mypdf+pos.

len = 134 - pos.

ENDIF.

ENDIF.

ENDLOOP.

IF len > 0.

APPEND outbin.

ENDIF.

ENDFORM. "doconv

how can i best deal with <b>i_tline</b> and send mail using <b>i_tline</b>.

thanks,

Subba