Send a pdf from spooler to an email address

Hi all,
as the subject says i am trying to send a pdf that exists in the spooler at an email address. Is there an FM that reads the pdf ?
As far as i can see all the procedures convert OTF to PDF, but i already have a pdf.
Any proposal is welcome, thank you in advance.
Regards,
Alex.

Hi you can do like this
data decleration for mail and pdf.
DATA : gt_listobject LIKE abaplist OCCURS 10 .
DATA : gt_objcont LIKE soli OCCURS 10 WITH HEADER LINE.
DATA : gt_objhead LIKE soli OCCURS 10 WITH HEADER LINE.
DATA : gt_att_head LIKE soli OCCURS 10 WITH HEADER LINE.
DATA : gt_receivers LIKE soos1 OCCURS 10 WITH HEADER LINE.
DATA : gt_packing_list LIKE soxpl OCCURS 10 WITH HEADER LINE.
DATA : gt_so_ali LIKE soli OCCURS 100 WITH HEADER LINE.
DATA : gt_so_ali1 LIKE soli OCCURS 100 WITH HEADER LINE.
DATA : gt_document_data LIKE sood1.
DATA: lineno TYPE i , length TYPE i , size TYPE i.
DATA: gt_scheme LIKE ztrc_scheme OCCURS 0 WITH HEADER LINE.
DATA: gd_recsize TYPE i.
Spool IDs
TYPES: BEGIN OF t_tbtcp.
INCLUDE STRUCTURE tbtcp.
TYPES: END OF t_tbtcp.
DATA: it_tbtcp TYPE STANDARD TABLE OF t_tbtcp INITIAL SIZE 0,
wa_tbtcp TYPE t_tbtcp.
Job Runtime Parameters
DATA: gd_eventid LIKE tbtcm-eventid,
gd_eventparm LIKE tbtcm-eventparm,
gd_external_program_active LIKE tbtcm-xpgactive,
gd_jobcount LIKE tbtcm-jobcount,
gd_jobname LIKE tbtcm-jobname,
gd_stepcount LIKE tbtcm-stepcount,
gd_error TYPE sy-subrc,
gd_reciever TYPE sy-subrc.
DATA: w_recsize TYPE i.
DATA: gd_subject LIKE sodocchgi1-obj_descr,
it_mess_bod LIKE solisti1 OCCURS 0 WITH HEADER LINE,
it_mess_att LIKE solisti1 OCCURS 0 WITH HEADER LINE,
gd_sender_type LIKE soextreci1-adr_typ,
gd_attachment_desc TYPE so_obj_nam,
gd_attachment_name TYPE so_obj_des.
Spool to PDF conversions
DATA: gd_spool_nr LIKE tsp01-rqident,
gd_destination LIKE rlgrap-filename,
gd_bytecount LIKE tst01-dsize,
gd_buffer TYPE string.
Binary store for PDF
DATA: BEGIN OF it_pdf_output OCCURS 0.
INCLUDE STRUCTURE tline.
DATA: END OF it_pdf_output.
CONSTANTS: c_dev LIKE sy-sysid VALUE 'DEV',
c_no(1) TYPE c VALUE ' ',
c_device(4) TYPE c VALUE 'LOCL'.
DATA: check TYPE c.
DATA: spid LIKE tsp01-rqident.
converting spool to pdf..
spid = syst-spono . " give your spool number here
CALL FUNCTION 'CONVERT_ABAPSPOOLJOB_2_PDF'
EXPORTING
src_spoolid = spid
TABLES
pdf = it_pdf_output.
CHECK sy-subrc = 0.
Transfer the 132-long strings to 255-long strings
LOOP AT it_pdf_output.
TRANSLATE it_pdf_output USING ' ~'.
CONCATENATE gd_buffer it_pdf_output INTO gd_buffer.
ENDLOOP.
TRANSLATE gd_buffer USING '~ '.
DO.
it_mess_att = gd_buffer.
APPEND it_mess_att.
SHIFT gd_buffer LEFT BY 255 PLACES.
IF gd_buffer IS INITIAL.
EXIT.
ENDIF.
ENDDO.
sending mail
DATA: p_email LIKE somlreci1-receiver,
p_sender LIKE somlreci1-receiver,
sub(40).
DESCRIBE TABLE it_mess_att LINES gd_recsize.
CHECK gd_recsize > 0.
REFRESH it_mess_bod.
Default subject matter
gd_subject = 'Subject'.
gd_attachment_desc = text-002.
it_mess_bod = text-001.
APPEND it_mess_bod.
IF p_sender EQ space.
gd_sender_type = space.
ELSE.
gd_sender_type = 'INT'.
ENDIF.
*concatenate sy-datum into sub separated by space.
MOVE 'Orders Released on' TO sub.
WRITE: sy-datum DD/MM/YYYY TO sub+27(10).
Send file by email as .xls speadsheet
PERFORM send_file_as_email_attachment
TABLES it_mess_bod
it_mess_att
USING
p_email
sub "text-003
'PDF'
gd_attachment_name
gd_attachment_desc
p_sender
gd_sender_type
CHANGING gd_error
gd_reciever.
ENDFORM. " process_email
*& Form send_file_as_email_attachment
text
-->P_IT_MESS_BOD text
-->P_IT_MESS_ATT text
-->P_TEXT_009 text
-->P_1058 text
-->P_GD_ATTACHMENT_NAME text
-->P_GD_ATTACHMENT_DESC text
<--P_GD_ERROR text
<--P_GD_RECIEVER text
FORM send_file_as_email_attachment TABLES it_message
it_attach
USING
p_email
p_mtitle
p_format
p_filename
p_attdescription
p_sender_address
p_sender_addres_type
CHANGING p_error
p_reciever.
DATA: ld_error TYPE sy-subrc,
ld_reciever TYPE sy-subrc,
ld_mtitle LIKE sodocchgi1-obj_descr,
ld_email LIKE somlreci1-receiver,
ld_format TYPE so_obj_tp ,
ld_attdescription TYPE so_obj_nam ,
ld_attfilename TYPE so_obj_des ,
ld_sender_address LIKE soextreci1-receiver,
ld_sender_address_type LIKE soextreci1-adr_typ,
ld_receiver LIKE sy-subrc.
DATA: t_packing_list LIKE sopcklsti1 OCCURS 0 WITH HEADER LINE,
t_contents LIKE solisti1 OCCURS 0 WITH HEADER LINE,
t_receivers LIKE somlreci1 OCCURS 0 WITH HEADER LINE,
t_attachment LIKE solisti1 OCCURS 0 WITH HEADER LINE,
t_object_header LIKE solisti1 OCCURS 0 WITH HEADER LINE,
w_cnt TYPE i,
w_sent_all(1) TYPE c,
w_doc_data LIKE sodocchgi1.
ld_email = p_email.
ld_mtitle = p_mtitle.
ld_format = p_format.
ld_attdescription = p_attdescription.
ld_attfilename = p_filename.
ld_sender_address = p_sender_address.
ld_sender_address_type = p_sender_addres_type.
Fill the document data.
w_doc_data-doc_size = 1.
Populate the subject/generic message attributes
w_doc_data-obj_langu = sy-langu.
w_doc_data-obj_name = 'SAPRPT'.
w_doc_data-obj_descr = ld_mtitle .
w_doc_data-sensitivty = 'F'.
Fill the document data and get size of attachment
CLEAR w_doc_data.
READ TABLE it_attach INDEX w_cnt.
w_doc_data-doc_size =
( w_cnt - 1 ) * 255 + STRLEN( it_attach ).
w_doc_data-obj_langu = sy-langu.
w_doc_data-obj_name = 'SAPRPT'.
w_doc_data-obj_descr = ld_mtitle.
w_doc_data-sensitivty = 'F'.
CLEAR t_attachment.
REFRESH t_attachment.
t_attachment[] = it_attach[].
Describe the body of the message
CLEAR t_packing_list.
REFRESH t_packing_list.
t_packing_list-transf_bin = space.
t_packing_list-head_start = 1.
t_packing_list-head_num = 0.
t_packing_list-body_start = 1.
DESCRIBE TABLE it_message LINES t_packing_list-body_num.
t_packing_list-doc_type = 'RAW'.
APPEND t_packing_list.
Create attachment notification
t_packing_list-transf_bin = 'X'.
t_packing_list-head_start = 1.
t_packing_list-head_num = 1.
t_packing_list-body_start = 1.
DESCRIBE TABLE t_attachment LINES t_packing_list-body_num.
t_packing_list-doc_type = ld_format.
t_packing_list-obj_descr = ld_attdescription.
t_packing_list-obj_name = ld_attfilename.
t_packing_list-doc_size = t_packing_list-body_num * 255.
APPEND t_packing_list.
Add the recipients email address
CLEAR t_receivers.
REFRESH t_receivers.
t_receivers-rec_type = 'U'.
t_receivers-com_type = 'INT'.
t_receivers-notif_del = 'X'.
t_receivers-notif_ndel = 'X'.
t_receivers-receiver = '[email protected]'.
APPEND t_receivers.
function module to send mail with pdf attachment
CALL FUNCTION 'SO_DOCUMENT_SEND_API1'
EXPORTING
document_data = w_doc_data
put_in_outbox = 'X'
sender_address = ld_sender_address
sender_address_type = ld_sender_address_type
commit_work = 'X'
IMPORTING
sent_to_all = w_sent_all
TABLES
packing_list = t_packing_list
contents_bin = t_attachment
contents_txt = it_message
receivers = t_receivers
EXCEPTIONS
too_many_receivers = 1
document_not_sent = 2
document_type_not_exist = 3
operation_no_authorization = 4
parameter_error = 5
x_error = 6
enqueue_error = 7
OTHERS = 8.
Populate zerror return code
ld_error = sy-subrc.
Populate zreceiver return code
LOOP AT t_receivers.
ld_receiver = t_receivers-retrn_code.
ENDLOOP.
this will work...for further calrification reply

Similar Messages

  • How do I email a group from a list of email addresses in a pdf?

    how do I email a group from a list of email addresses in a pdf?

    Work Around:
    On your mac:
    1.  Open a new email
    2.  Insert name of an existing group into one of the "To" fields as usual.
    3.  Highlight all the resulting names in the "To" entry
         [Highlight first name, and while holding shift, highlight last name and all will highlight[]
    4. Copy (Command C) the highlighted emails
    5. Paste (Command V) nto a pages document
    6. Remove the name and anything else preceeding the first < and also the first < of only the first entry whixh will look like this:
         [email protected]>,
    7. Remove the > of the last email which will look like this:
         , Jane Doe <[email protected]
    8. Copy the entire altered list from the pages document
    9, Go to Contact Book and click + to add a new entry
    10.. Name the entry (XXX Group for iPad) or whatever you wish to call it
    11.  Paste all the copied altered list into any one of the email entry spaces
    12.  Click on "Done"
    13.  Create new email On iPad and click on + in any one of the "To" lines and search for "XXX Group for iPad"  You cannot just key in XXX Group for iPad!!!!!!!, you must use + contact search.
    14.  Enter the selected iPad contact group into the "To" line.
    15.  All the entries will now appear in the "To" line and you are good to go.
    Adding or deleting email addresses from the iPad group:
    Easiest:  Alter the original mac group in the usual way and repeat steps 1-14 above.  It seems impossible to edit within the emai line of the iPad contact entry.
    Rediculously simple once figured out.
    Happy emailling, but please send Bcc so that you don't spread your groups' email addresses all over the internet for spam, viruses, and other unwanted emails.  Be considerate and ask your recipients to notifiy you if they wish to be deleted from the lists you compose.

  • Send a message from a list of emails in lightswitch 2013.4 HTML screen using ajax

    Hi There,
    any idea how to make a button to send a message from a list of emails in lightswitch 2013.4 HTML.
    my idea is to send message to all emails in the details picker (or the drop down menu or a choice list) tat is filled by SQL query (as a data source in lightswitch)
    i have read many articles,  most of them were written in PHP or VB !
    for example:
    http://www.devarticles.com/c/a/HTML/Sending-email-with-AJAX-building-a-small-application/1/
    http://stackoverflow.com/questions/22442074/how-to-send-email-to-a-list-of-addresses-from-lightswitch
    http://lightswitchhelpwebsite.com/Forum/tabid/63/aft/75/Default.aspx
    http://maxslabyak.com/c-sharp/using-jquery-to-send-email-with-web-services/
    http://www.paulspatterson.com/microsoft-lightswitch-sending-emails-from-the-client/
    http://www.quercussolutions.com/blog/index.php/microsoft-lightswitch-sending-emails/
    http://www.lightswitchspecial.com/2013/01/7-most-easiest-way-to-send-email-from.html
    as far as  i know, the HTML screens in lightswitch 2013 can be encoded with ajax only, not vb or C# any more!
    my project contains only HTML screens, no desktop screens. i know that i can do the VB programming in the tables actions, but i am looking to have this code in the Browse screen to give me more flexibility depending on my decision to
    send or not..
    help please :)  

    Hello Hasan,
    I do this using a generic handler(e.g. sendmail.ashx). In the ashx file i use this code:
    Imports System.Net.Mail
    Imports System.Web
    Imports System.Web.Services
    Sub ProcessRequest(ByVal context As HttpContext) Implements IHttpHandler.ProcessRequest
    Dim str As String = "there was no error "
    Dim Recipient As String = Convert.ToString(context.Request.Params("pRecipient"))
    Dim strsub As String = Convert.ToString(context.Request.Params("pSubject"))
    Dim strmsg As String = Convert.ToString(context.Request.Params("pMessage"))
    Dim msg As New MailMessage
    Try
    ' Your mail address and display name.
    ' This what will appear on the From field.
    ' If you used another credentials to access
    ' the SMTP server, the mail message would be
    ' sent from the mail specified in the From
    ' field on behalf of the real sender.
    msg.From = New MailAddress("[email protected]", "Displayname")
    ' To addresses
    msg.To.Add("[email protected]")
    'msg.To.Add(New MailAddress("[email protected]", "Friend B"))
    ' You can specify CC and BCC addresses also
    ' Set to high priority
    msg.Priority = MailPriority.High
    msg.Subject = strsub
    ' You can specify a plain text or HTML contents
    msg.IsBodyHtml = True
    msg.Body = strmsg
    'msg.Body = _
    ' "Hello everybody,<br /><br />" & _
    ' "I found an interesting site called <a href=""http:'JustLikeAMagic.WordPress.com"">" & _
    ' "Just Like a Magic</a>. Be sure to visit it soon."
    ' In order for the mail client to interpret message
    ' body correctly, we mark the body as HTML
    ' because we set the body to HTML contents.
    ' Attaching some data
    ' msg.Attachments.Add(New Attachment("D:\Site.lnk"))
    ' Connecting to the server and configuring it
    Dim client As New SmtpClient()
    client.Host = "mail.gmx.com"
    client.Port = 25
    client.EnableSsl = True
    ' The server requires user's credentials
    ' not the default credentials
    client.UseDefaultCredentials = False
    ' Provide your credentials
    client.Credentials = New System.Net.NetworkCredential("yourcredentias", "f2f081639ad")
    client.DeliveryMethod = SmtpDeliveryMethod.Network
    ' Use SendAsync to send the message asynchronously
    client.Send(msg)
    Catch ex As Exception
    str = ex.Message
    Finally
    msg.Dispose()
    End Try
    context.Response.ContentType = "text/plain"
    context.Response.Write(str)
    End Sub
    When you create the ASHX then replace the ProcessRequest with the above function.
    In LS HTML Screen create the function for pressing a button an appen the following text:
    $.ajax({
    type: 'post',
    data: {
    pRecipient: Screen.yourdata,
    pSubject: Screen.yourdata,
    pMessage: Screen.yourdata,
    url: '../sendmail.ashx',
    success: function success(result) {
    alert(result);
    This is a way you can do that. In VB and out of your browse Screen.
    Hope this helps
    Thomas

  • Determine size of pdf from spool

    All,
    does anyone know how to determine size of pdf from spool.
    i'm using RSPO_RETURN_ABAP_SPOOLJOB to get pdf file, but i want to know its size.
    any idea?

    Assume the PDF data is in internal table gt_messg_att.
    MOVE p_spoolno TO lv_spoolno.
    * CONVERT THE SPOOL TO PDF
      CALL FUNCTION 'CONVERT_OTFSPOOLJOB_2_PDF'
        EXPORTING
          src_spoolid                    = lv_spoolno
          no_dialog                      = lc_no_dialog
    *     DST_DEVICE                     =
    *     PDF_DESTINATION                =
       IMPORTING
         pdf_bytecount                  = lv_bytecount
    *     PDF_SPOOLID                    =
    *     OTF_PAGECOUNT                  =
    *     BTC_JOBNAME                    =
    *     BTC_JOBCOUNT                   =
       TABLES
         pdf                            = gt_pdf_output
       EXCEPTIONS
         err_no_otf_spooljob            = 1
         err_no_spooljob                = 2
         err_no_permission              = 3
         err_conv_not_possible          = 4
         err_bad_dstdevice              = 5
         user_cancelled                 = 6
         err_spoolerror                 = 7
         err_temseerror                 = 8
         err_btcjob_open_failed         = 9
         err_btcjob_submit_failed       = 10
         err_btcjob_close_failed        = 11
         OTHERS                         = 12
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ELSE.
    * Transfer the 132-long strings to 255-long strings
        LOOP AT gt_pdf_output INTO wa_pdf_output.
          TRANSLATE wa_pdf_output USING ' ~'.
          CONCATENATE v_buffer wa_pdf_output INTO v_buffer.
          MODIFY gt_pdf_output FROM wa_pdf_output.
          CLEAR wa_pdf_output.
        ENDLOOP.
    * TO CONVERT THE DATA INTO PDF FORMAT ELSE THE PDF FILE
    * WON'T OPEN & REPORT WOULD GIVE A MESSAGE THAT
    * THE FILE IS DAMAGED & COULD NOT BE OPENED
        TRANSLATE v_buffer USING '~ '.
        CLEAR : wa_messg_att,
                gt_messg_att.
        DO.
          wa_messg_att = v_buffer.
          APPEND wa_messg_att TO gt_messg_att.
          SHIFT v_buffer LEFT BY 255 PLACES.
          IF v_buffer IS INITIAL.
            EXIT.
          ENDIF.
          CLEAR wa_messg_att.
        ENDDO.
      ENDIF.
    * Get size of attachment
      DESCRIBE TABLE gt_messg_att LINES lv_cnt.
      READ TABLE gt_messg_att INTO wa_messg_att INDEX lv_cnt.
      lwa_doc_data-doc_size =  ( lv_cnt - 1 ) * 255 + STRLEN( wa_messg_att ).

  • How do i protect pdf from being forwarded by email?

    how do i protect pdf from being forwarded by email?@

    There's nothing at all you can do to stop a PDF from being copied, emailed, put in a USB stick, uploaded to DropBox, or shared in any other way. DRM ($$$$) can make it so that unauthorized copies cannot be opened.

  • Can i send a pdf from imac to iphone or smart phone

    can i send a pdf from imac to iphone
    other than as a mail attachment?

    Hi.
    Yes. You can drag the pdf file into the Books display window in iTunes, then sync your iPhone. The pdf will make itself available in the iBooks app on your iPhone.
    Look at this... iBooks: Viewing, syncing, saving, and printing PDFs on iPhone, iPad, and iPod touch
    I hope this helps.

  • Need a way to verify from SAP if an email address really exists

    Hi Guru,
    I need a way to verify from SAP if an email address really exists.
    Thanks in advance
    Soufiene

    Hello,
    Try the following code. It gives an option of using a webservice to validate an email address. This piece of code may help in solving your query.
    PARAMETERS: p_mail(100) LOWER CASE.                 " E-Mail id to be verified
    DATA: http_client TYPE REF TO if_http_client .
    DATA: w_string TYPE string ,
          w_result TYPE string ,
          r_str    TYPE string .
    DATA: result_tab TYPE TABLE OF string.
    START-OF-SELECTION .
      CLEAR w_string .
      CONCATENATE
      'http://www.webservicex.net/ValidateEmail.asmx/IsValidEmail?Email=' p_mail
    INTO
      w_string .
      CALL METHOD cl_http_client=>create_by_url
        EXPORTING
          url                = w_string
        IMPORTING
          client             = http_client
        EXCEPTIONS
          argument_not_found = 1
          plugin_not_active  = 2
          internal_error     = 3
          OTHERS             = 4.
       CALL METHOD http_client->send
        EXCEPTIONS
          http_communication_failure = 1
          http_invalid_state         = 2.
        CALL METHOD http_client->receive
        EXCEPTIONS
          http_communication_failure = 1
          http_invalid_state         = 2
          http_processing_failed     = 3.
      CLEAR w_result .
      w_result = http_client->response->get_cdata( ).
       REFRESH result_tab .
      SPLIT w_result AT cl_abap_char_utilities=>cr_lf INTO TABLE result_tab .
       READ TABLE result_tab INTO r_str INDEX 2.
      IF r_str+44(1) = 't'.
        WRITE:/ 'Valid email address'.
      ELSE.
        WRITE:/ 'Invalid email address'.
      ENDIF.
    Regards,
    Sachin

  • I updated my iPhone 4S weeks ago and today it said I needed to update it again, so I did. Now when I send iMessage it comes up with my email address and not my number. How do I fix this?

    I updated my iPhone 4S weeks ago and today it said I needed to update it again, so I did. Now when I send iMessage it comes up with my email address and not my number. How do I fix this?

    The Snow Leopard 10.6 DVD should still be available from Apple for $20. You will have to call Apple Customer Care 1-800-692-7753 or 1-800-676-2775 to purchase it. It may still be in the Legacy Products list. The App Store which is required to download 10.7 or 10.8 is part of the 10.6.6 update.
    If they no longer have any in stock you will have to buy it from eBay or Apple resellers that still have stock. But you will have to pay a premium since the DVDs are no longer being made. Snow Leopard DVDs are already up to $100 on Amazon.
    http://www.ebay.com/sch/i.html?_nkw=10.6+snow+leopard&_sacat=0&_odkw=mac+os+10.6 &_osacat=0

  • Cant send iCal Invite to myself or alternate email address

    I've been having a challenge creating an iCal event and sending an invitation to myself. What Im trying to do is add an appointment to my calendar on my personal Mac and have an invitation sent to my work email address so I can add the appointment to my work calendar also.
    Apparently iCal will not let you send a invite to any of the email addresses in the "Me" address book entry.
    I tried adding a new address book entry for just my work email address but that did not work either.
    I had to REMOVE my work email address from the ME address book entry before the work address book entry would show up.
    Gary

    Hi,
    You can turn on text messaging notification in OWA to receive message notification, but the premise is that you can logon OWA. If you don't have access to OWA, you can create a transport rule to forward the messages you received to another user's mailbox,
    and then set up his/her OWA to send text messages to your mobile device.
    Hope my clarification can be helpful to you.
    Best regards,
    Amy Wang
    TechNet Community Support

  • I am trying to change my apple Id on my iPad from an old work email address to a new one.  I have changed it in FaceTime and on the iPad log in but can't get it to change in iTunes. Any ideas?

    I am trying to change my Apple ID on my iPad from an old work email address to a new personal address.  I have changed it on my new iPad and in FaceTime but can't get it to work in iTunes.  Any ideas?

    If they are no longer in your camera roll, save them to your camera roll before deleting the account (open your my photo stream album, tap Select, tap the photos, tap the share icon -- box with upward pointing arrow, the tap Save to Camera Roll).

  • How to get my Name in the From Field instead of email address?

    For an Exchange Activesync account, how do you get your friendly "Name" to show in the From: field rather than email address ([email protected])?
    I seem to be able to do this fro IMAP/POP accounts but not Exchange Activesync.
    All the discussions I've found about gmail and Activesync seem to be centered on getting your messages to show a different return email address than your exchange account. I'm not looking for this, just to show the Name.
    Thanks

    If you add a contact ("Contacts app>> "+">> enter info) with that email address, it will appear in mail with whatever name you set in the email address' contact.

  • Is it possible to send a PDF to a specific e-mail address only?

    Is it possible to send a PDF to a specific e-mail address so that it cannot be re-sent by the recipient to another address?  I.e. goes to one person & no further.
    http://mcatprep.yolasite.com/
    <a href=http://mcatprep.yolasite.com/>M Prep</a>

    http://help.adobe.com/en_US/Acrobat/9.0/Professional/WS58a04a822e3e50102bd615109794195ff-7 d9c.w.html
    check out the portion that says you can apply security so only a specified person can open the file

  • How do I send docs to multiple signators with different email addresses on Echo sign ?

    How do I send docs to multiple signators with different email addresses on Echo sign ?

    Thanks man...the problem could be on the signators side.
    Rick Schell...Realtor, ABR
    www.rick-the-realtor.com
    Cell 615-804-3085
    Crye-Leike Realtors
    Office 615-373-3513
    Fax 615-373-5228
    Quoting Echosign-Rob <[email protected]>:
    Echosign-Rob  created 
    the discussion
    "How do I send docs to multiple signators with different email 
    addresses on Echo sign ?"
    To view the discussion, visit: 
    https://forums.adobe.com/message/6395941#6395941
    >

  • How to send converted PDF from OTF via email

    Hi Experts,
    Greetings! How can I send the PDF file from FM 'CONVERT_OTF' via email?
    I was stuck on this code:
    *--- Convert OTF data to pdf
      CLEAR: i_otf, i_pdf.
      i_otf[] = gs_ssfcrescl-otfdata.
      CALL FUNCTION 'CONVERT_OTF'
        EXPORTING
          format                = 'PDF'
          max_linewidth         = 132
        IMPORTING
          bin_filesize          = v_bin_filesize
        TABLES
          otf                   = i_otf
          lines                 = i_pdf
        EXCEPTIONS
          err_max_linewidth     = 1
          err_format            = 2
          err_conv_not_possible = 3
          err_bad_otf           = 4
          OTHERS                = 5.
      CHECK sy-subrc = 0 AND NOT i_pdf[] IS INITIAL.
    Thanks in advance for the help.

    Hi
    DATA:
    I_OTF TYPE ITCOO OCCURS 0 WITH HEADER LINE,
    I_TLINE TYPE TABLE OF TLINE WITH HEADER LINE,
    I_RECEIVERS TYPE  TABLE OF SOMLRECI1 WITH HEADER LINE,
    I_RECORD LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
    I_OBJPACK LIKE SOPCKLSTI1 OCCURS 0 WITH HEADER LINE,
    I_OBJTXT LIKE SOLISTI1 OCCURS 0 WITH HEADER LINE,
    I_OBJBIN LIKE SOLISTI1  OCCURS 0 WITH HEADER LINE,
    I_RECLIST LIKE SOMLRECI1  OCCURS 0 WITH HEADER LINE.
    DATA:
      W_OBJHEAD TYPE SOLI_TAB,
      W_CTRLOP TYPE SSFCTRLOP,
      W_COMPOP TYPE SSFCOMPOP,
      W_RETURN TYPE SSFCRESCL,
      W_DOC_CHNG TYPE SODOCCHGI1,
      W_DATA TYPE SODOCCHGI1,
      W_BUFFER TYPE STRING.
    DATA:
    V_FORM_NAME TYPE RS38L_FNAM,
    V_LEN_IN LIKE SOOD-OBJLEN,
    V_LEN_OUT LIKE SOOD-OBJLEN,
    V_LEN_OUTN TYPE I,
    V_LINES_TXT TYPE I,
    V_LINES_BIN TYPE I.
    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
      EXPORTING
        FORMNAME           = ' '---------> smartform
      IMPORTING
        FM_NAME            = V_FORM_NAME
      EXCEPTIONS
        NO_FORM            = 1
        NO_FUNCTION_MODULE = 2.
    IF SY-SUBRC <> 0.
      MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
      WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    W_CTRLOP-GETOTF = 'X'.
    W_CTRLOP-NO_DIALOG = 'X'.
    W_COMPOP-TDNOPREV = 'X'.
    CALL FUNCTION '/1BCDWB/SF00000482'
      EXPORTING
        CONTROL_PARAMETERS = W_CTRLOP
        OUTPUT_OPTIONS     = W_COMPOP
        USER_SETTINGS      = 'X'
      IMPORTING
        JOB_OUTPUT_INFO    = W_RETURN
      EXCEPTIONS
        FORMATTING_ERROR   = 1
        INTERNAL_ERROR     = 2
        SEND_ERROR         = 3
        USER_CANCELED      = 4.
    IF SY-SUBRC <> 0.
      MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
      WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    I_OTF[] = W_RETURN-OTFDATA[].
    CALL FUNCTION 'CONVERT_OTF'
      EXPORTING
        FORMAT                = 'PDF'
        MAX_LINEWIDTH         = 132
      IMPORTING
        BIN_FILESIZE          = V_LEN_IN
      TABLES
        OTF                   = I_OTF
        LINES                 = I_TLINE
      EXCEPTIONS
        ERR_MAX_LINEWIDTH     = 1
        ERR_FORMAT            = 2
        ERR_CONV_NOT_POSSIBLE = 3
        ERR_BAD_OTF           = 4.
    IF SY-SUBRC <> 0.
      MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
      WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    LOOP AT I_TLINE.
      TRANSLATE I_TLINE USING '~'.
      CONCATENATE W_BUFFER I_TLINE INTO W_BUFFER.
    ENDLOOP.
    TRANSLATE W_BUFFER USING '~'.
    DO.
      I_RECORD = W_BUFFER.
      APPEND I_RECORD.
      SHIFT W_BUFFER LEFT BY 255 PLACES.
      IF W_BUFFER IS INITIAL.
        EXIT.
      ENDIF.
    ENDDO.
    REFRESH :
      I_RECLIST,
      I_OBJTXT,
      I_OBJBIN,
      I_OBJPACK.
    CLEAR W_OBJHEAD.
    I_OBJBIN[] = I_RECORD[].
    DESCRIBE TABLE I_OBJBIN LINES V_LINES_BIN.
    I_OBJTXT = 'Find attached the output of the smartform.'.
    APPEND I_OBJTXT.
    I_OBJTXT = 'Regards,'.
    APPEND I_OBJTXT.
    I_OBJTXT = 'Sravanthi'.
    APPEND I_OBJTXT.
    DESCRIBE TABLE I_OBJTXT LINES V_LINES_TXT.
    W_DOC_CHNG-OBJ_NAME = 'Smartform'.
    W_DOC_CHNG-EXPIRY_DAT = SY-DATUM + 10 .
    W_DOC_CHNG-OBJ_DESCR  = 'Smart form output'.
    W_DOC_CHNG-SENSITIVTY = 'F'.
    W_DOC_CHNG-DOC_SIZE = V_LINES_TXT * 255.
    CLEAR I_OBJPACK-TRANSF_BIN.
    I_OBJPACK-HEAD_START = 1.
    I_OBJPACK-HEAD_NUM = 0.
    I_OBJPACK-BODY_START = 1.
    I_OBJPACK-BODY_NUM = V_LINES_TXT.
    I_OBJPACK-DOC_TYPE = 'RAW'.
    APPEND I_OBJPACK.
    I_OBJPACK-TRANSF_BIN = 'X'.
    I_OBJPACK-HEAD_START = 1.
    I_OBJPACK-HEAD_NUM = 1.
    I_OBJPACK-BODY_START = 1.
    I_OBJPACK-BODY_NUM = V_LINES_BIN.
    I_OBJPACK-DOC_TYPE  = 'PDF'.
    I_OBJPACK-OBJ_NAME = 'Smartform'.
    CONCATENATE 'smartform output' 'pdf'
    INTO I_OBJPACK-OBJ_DESCR.
    I_OBJPACK-DOC_SIZE = V_LINES_BIN * 255.
    APPEND I_OBJPACK.
    CLEAR I_RECLIST.
    I_RECLIST-RECEIVER = ' '.---------->email id
    I_RECLIST-EXPRESS  = 'X'.
    I_RECLIST-REC_TYPE  = 'U'.
    APPEND I_RECLIST.
    CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'
      EXPORTING
        DOCUMENT_DATA              = W_DOC_CHNG
        PUT_IN_OUTBOX              = 'X'
        commit_work                = 'X'
      TABLES
        PACKING_LIST               = I_OBJPACK
       CONTENTS_BIN                = I_OBJBIN
        OBJECT_HEADER              = W_OBJHEAD
        CONTENTS_TXT               = I_OBJTXT
        RECEIVERS                  = I_RECLIST
      EXCEPTIONS
        TOO_MANY_RECEIVERS         = 1
        DOCUMENT_NOT_SENT          = 2
        DOCUMENT_TYPE_NOT_EXIST    = 3
        OPERATION_NO_AUTHORIZATION = 4
        PARAMETER_ERROR            = 5
        X_ERROR                    = 6
        ENQUEUE_ERROR              = 7
        OTHERS                     = 8.
    IF sy-subrc NE 0.
          WRITE:/ 'Error When Sending the File', sy-subrc.
        ELSE.
          WRITE:/ 'Mail sent'.
        ENDIF.
    After excuting this program check the status of the email in the SOST  transaction
    Regards,
    sravanthi

  • When I send a pdf from my pc to ipad the pdf is already open when I scroll down the message so I am unable to save to the ibooks, any suggestions

    When I send a pdf as an attachment from my windows pc to the ipad via outlook mail there are occasions when the pdf is open on the email and not as an attachment which means I cannot store this on ibooks, any suggestions.

    If the document is already open then, if you touch and hold in the body of the document, you will be given a set of options. One of these is to "Open in iBooks".

Maybe you are looking for

  • How to print my report to pdf silently

    Hi , I have develop a program and that can print report to physical print automatically. Now I want to print them to pdf file automatically,  it prints about 1000 report a day. and the file name will be different each one, the filename will like :{re

  • Discount after exise and before VAT

    Hi, We have a requirement like this Basic Price Rs.100/- Excise 10%       10/- Discount       Rs 20/- Vat 4%        Rs.3.60/-  (100+10-20=90*4) I am not able to resolve this requirement in 5.0 and 6.0 I have resolved in 4,7 by using sub total 6 in Di

  • Sort by metadata fields

    Is there a way to extend Lightroom to sort by additional metadata fields in Library module? I really would like to sort by Title or Caption most of the time.

  • Create/copy existing FM

    Hi, I have problems when I want to copy a simple FM. The copied FM can't be activated. The error mesage appears  REPORT/PROGRAM statement missing, or program type is INCLUDE. What is the problem. The source FM works fine.... Thanks in advance Sau0161

  • Domino REGNEWUSER error

    We received this error in IdM 6.1 when creating a user account on Lotus Notes 6.5: DOMINOEXTENSION::ERROR WHILE EXECUTING 'WS_REGNEWUSER' ERRCODE: '16646'. INSUFFICIENT DISK SPACE We have enough disk space, though. Did anyone else see this error befo