<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Send Email from the REport program in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542633#M247087</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;THe code below may help u.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM send_mail USING  p_y16m_rcp_par STRUCTURE y16m_rcp_par.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Have a subject for the mail&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  g_s_document_data-obj_name = text-t02.&lt;/P&gt;&lt;P&gt;  g_s_document_data-obj_descr = text-t03.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Fill receiver information&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  g_s_receivers-rec_type = p_y16m_rcp_par-rec_type.&lt;/P&gt;&lt;P&gt;  g_s_receivers-rec_id = p_y16m_rcp_par-rec_id.&lt;/P&gt;&lt;P&gt;  g_s_receivers-express = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND g_s_receivers TO g_t_receivers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Call function to send mail&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;            document_data              = g_s_document_data&lt;/P&gt;&lt;P&gt;           document_type              = 'RAW'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         PUT_IN_OUTBOX              = ' '&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         SENT_TO_ALL                =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         NEW_OBJECT_ID              =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;       TABLES&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         OBJECT_HEADER              =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;           object_content             =  g_t_object_content&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         CONTENTS_HEX               =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         OBJECT_PARA                =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         OBJECT_PARB                =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;            receivers                  = g_t_receivers&lt;/P&gt;&lt;P&gt;      EXCEPTIONS&lt;/P&gt;&lt;P&gt;           too_many_receivers         = 1&lt;/P&gt;&lt;P&gt;           document_not_sent          = 2&lt;/P&gt;&lt;P&gt;           document_type_not_exist    = 3&lt;/P&gt;&lt;P&gt;           operation_no_authorization = 4&lt;/P&gt;&lt;P&gt;           parameter_error            = 5&lt;/P&gt;&lt;P&gt;           x_error                    = 6&lt;/P&gt;&lt;P&gt;           enqueue_error              = 7&lt;/P&gt;&lt;P&gt;           OTHERS                     = 8&lt;/P&gt;&lt;P&gt;            .&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno&lt;/P&gt;&lt;P&gt;            WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.                    " SEND_MAIL&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 07 Sep 2006 13:03:57 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-09-07T13:03:57Z</dc:date>
    <item>
      <title>Send Email from the REport program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542628#M247082</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;HI all,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am checking the expiratio date of the user id and if it is very nearer then I need tto send them email with some message from my program . So can you please give me function module or &amp;lt;b&amp;gt;code&amp;lt;/b&amp;gt; how I can send email to employees &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 12:30:36 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542628#M247082</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T12:30:36Z</dc:date>
    </item>
    <item>
      <title>Re: Send Email from the REport program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542629#M247083</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can use function module SO_NEW_DOCUMENT_ATT_SEND_API1 for sending email with attachment. You can view the Function module documentation which have details regarding implementation with sample code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Imtiaz Ahmed&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 12:32:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542629#M247083</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T12:32:33Z</dc:date>
    </item>
    <item>
      <title>Re: Send Email from the REport program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542630#M247084</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is an example code for you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;REPORT  zramki_submit_self                      .&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;PARAMETERS:&lt;/P&gt;&lt;P&gt; p_date LIKE sy-datum DEFAULT sy-datum,&lt;/P&gt;&lt;P&gt; p_submit NO-DISPLAY.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;IF p_submit IS INITIAL.&lt;/P&gt;&lt;P&gt;  SUBMIT (sy-repid) WITH p_date   = p_date&lt;/P&gt;&lt;P&gt;                    WITH p_submit = 'X'&lt;/P&gt;&lt;P&gt;               EXPORTING LIST TO MEMORY AND RETURN.&lt;/P&gt;&lt;UL&gt;&lt;UL&gt;&lt;UL&gt;&lt;LI level="3" type="ul"&gt;&lt;P&gt;Process the list here and send the mail &lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/UL&gt;&lt;/UL&gt;&lt;P&gt;ELSE.&lt;/P&gt;&lt;UL&gt;&lt;UL&gt;&lt;UL&gt;&lt;LI level="3" type="ul"&gt;&lt;P&gt;Generate the report here.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;/UL&gt;&lt;/UL&gt;&lt;P&gt;  do 5 times.  &lt;/P&gt;&lt;P&gt;    WRITE: /1 sy-index, sy-datum.&lt;/P&gt;&lt;P&gt;  enddo.&lt;/P&gt;&lt;P&gt;  EXIT.&lt;/P&gt;&lt;P&gt;ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ram&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Pls reward points if helpful&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 12:33:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542630#M247084</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T12:33:01Z</dc:date>
    </item>
    <item>
      <title>Re: Send Email from the REport program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542631#M247085</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;A href="http://www.sapdevelopment.co.uk/reporting/email/attach_xls.htm" target="test_blank"&gt;http://www.sapdevelopment.co.uk/reporting/email/attach_xls.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if you want to send email to the SAP user then&lt;/P&gt;&lt;P&gt;receivers-REC_TYP = 'B'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or if you want to send it to an internet mail id,&lt;/P&gt;&lt;P&gt;then REC_TYP = 'U'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can use the same function module to send for either of them.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards&lt;/P&gt;&lt;P&gt;srikanth&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Srikanth Kidambi&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 12:34:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542631#M247085</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T12:34:10Z</dc:date>
    </item>
    <item>
      <title>Re: Send Email from the REport program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542632#M247086</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hi ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;kindly chekc the code below.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*&amp;amp;      Form  f_send_mail&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;amp;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;      text&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; --&amp;gt;  p1        text&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt; &amp;lt;--  p2        text&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;STRONG&gt;----&lt;/STRONG&gt;&lt;/P&gt;&lt;HR originaltext="-----------------------------------------------------------------" /&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM f_send_mail .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: objpack   LIKE sopcklsti1 OCCURS 2 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: objhead   LIKE solisti1 OCCURS 1 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: objbin    LIKE solisti1 OCCURS 10 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: objtxt    LIKE solisti1 OCCURS 10 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: reclist   LIKE somlreci1 OCCURS 5 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA: doc_chng  LIKE sodocchgi1.&lt;/P&gt;&lt;P&gt;DATA: tab_lines LIKE sy-tabix.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;*store the vendor name, vendor email id , employee name and employee&lt;/P&gt;&lt;P&gt;*email id in the internal table int_crb&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Creation of the document to be sent&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CLEAR doc_chng.&lt;/P&gt;&lt;P&gt;  REFRESH objpack.&lt;/P&gt;&lt;P&gt;  REFRESH objhead.&lt;/P&gt;&lt;P&gt;  REFRESH  reclist.&lt;/P&gt;&lt;P&gt;  REFRESH objtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;File Name&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  doc_chng-obj_name = 'SHIPMENT'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Mail Subject&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CONCATENATE 'Shipment Document No.' int_crb_mail-shipdocnum&lt;/P&gt;&lt;P&gt;  'Cleared.'&lt;/P&gt;&lt;P&gt;  INTO doc_chng-obj_descr SEPARATED BY ' '.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Mail Contents&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  objtxt-line = 'Hi,'.&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  objtxt-line = ' '.&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CONCATENATE 'Shipment Document Number ' int_crb_mail-shipdocnum&lt;/P&gt;&lt;P&gt;' cleared for move.' INTO objtxt-line SEPARATED BY ' '.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;  objtxt-line = ' '.&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CLEAR  objtxt.&lt;/P&gt;&lt;P&gt;  objtxt-line = 'Regards '.&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  objtxt-line = ' '.&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  objtxt-line = 'SAP '.&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;  CLEAR  objtxt.&lt;/P&gt;&lt;P&gt;  APPEND objtxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  DESCRIBE TABLE objtxt LINES tab_lines.&lt;/P&gt;&lt;P&gt;  READ TABLE objtxt INDEX tab_lines.&lt;/P&gt;&lt;P&gt;  doc_chng-doc_size = ( tab_lines - 1 ) * 255 + STRLEN(&lt;/P&gt;&lt;P&gt;objtxt ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Creation of the entry for the compressed document&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CLEAR objpack-transf_bin.&lt;/P&gt;&lt;P&gt;  objpack-head_start = 1.&lt;/P&gt;&lt;P&gt;  objpack-head_num = 0.&lt;/P&gt;&lt;P&gt;  objpack-body_start = 1.&lt;/P&gt;&lt;P&gt;  objpack-body_num = tab_lines.&lt;/P&gt;&lt;P&gt;  objpack-doc_type = 'RAW'.&lt;/P&gt;&lt;P&gt;  APPEND objpack.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Completing the recipient list&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;target recipent&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CLEAR reclist.&lt;/P&gt;&lt;P&gt;  reclist-receiver = int_crb_mail-empperid. "employee email ID&lt;/P&gt;&lt;P&gt;  "wf_empperid.&lt;/P&gt;&lt;P&gt;  reclist-express  = 'X'.&lt;/P&gt;&lt;P&gt;  reclist-rec_type = 'U'.&lt;/P&gt;&lt;P&gt;  APPEND reclist.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;copy recipents&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  CLEAR reclist.&lt;/P&gt;&lt;P&gt;  reclist-receiver = int_crb_mail-smtp_addr."vendor email id&lt;/P&gt;&lt;P&gt;  reclist-express  = 'X'.&lt;/P&gt;&lt;P&gt;  reclist-rec_type = 'U'.&lt;/P&gt;&lt;P&gt;  reclist-copy     = 'X'.&lt;/P&gt;&lt;P&gt;  APPEND reclist.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Sending the document&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  CALL FUNCTION 'SO_NEW_DOCUMENT_ATT_SEND_API1'&lt;/P&gt;&lt;P&gt;    EXPORTING&lt;/P&gt;&lt;P&gt;      document_data              = doc_chng&lt;/P&gt;&lt;P&gt;    TABLES&lt;/P&gt;&lt;P&gt;      packing_list               = objpack&lt;/P&gt;&lt;P&gt;      object_header              = objhead&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;   contents_bin               = objbin&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;      contents_txt               = objtxt&lt;/P&gt;&lt;P&gt;      receivers                  = reclist&lt;/P&gt;&lt;P&gt;    EXCEPTIONS&lt;/P&gt;&lt;P&gt;      too_many_receivers         = 1&lt;/P&gt;&lt;P&gt;      document_not_sent          = 2&lt;/P&gt;&lt;P&gt;      operation_no_authorization = 4&lt;/P&gt;&lt;P&gt;      OTHERS                     = 99.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;hope this wiil help u.&lt;/P&gt;&lt;P&gt;for any clarifivation pls mail&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;kindly reward points if this helped u.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;anversha.&lt;/P&gt;&lt;P&gt;anversha.shahul@wipro.com&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 12:40:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542632#M247086</guid>
      <dc:creator>anversha_s</dc:creator>
      <dc:date>2006-09-07T12:40:38Z</dc:date>
    </item>
    <item>
      <title>Re: Send Email from the REport program</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542633#M247087</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;THe code below may help u.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM send_mail USING  p_y16m_rcp_par STRUCTURE y16m_rcp_par.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Have a subject for the mail&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  g_s_document_data-obj_name = text-t02.&lt;/P&gt;&lt;P&gt;  g_s_document_data-obj_descr = text-t03.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Fill receiver information&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  g_s_receivers-rec_type = p_y16m_rcp_par-rec_type.&lt;/P&gt;&lt;P&gt;  g_s_receivers-rec_id = p_y16m_rcp_par-rec_id.&lt;/P&gt;&lt;P&gt;  g_s_receivers-express = 'X'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  APPEND g_s_receivers TO g_t_receivers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Call function to send mail&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'&lt;/P&gt;&lt;P&gt;       EXPORTING&lt;/P&gt;&lt;P&gt;            document_data              = g_s_document_data&lt;/P&gt;&lt;P&gt;           document_type              = 'RAW'&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         PUT_IN_OUTBOX              = ' '&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;    IMPORTING&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         SENT_TO_ALL                =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         NEW_OBJECT_ID              =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;       TABLES&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         OBJECT_HEADER              =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;           object_content             =  g_t_object_content&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         CONTENTS_HEX               =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         OBJECT_PARA                =&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;         OBJECT_PARB                =&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;            receivers                  = g_t_receivers&lt;/P&gt;&lt;P&gt;      EXCEPTIONS&lt;/P&gt;&lt;P&gt;           too_many_receivers         = 1&lt;/P&gt;&lt;P&gt;           document_not_sent          = 2&lt;/P&gt;&lt;P&gt;           document_type_not_exist    = 3&lt;/P&gt;&lt;P&gt;           operation_no_authorization = 4&lt;/P&gt;&lt;P&gt;           parameter_error            = 5&lt;/P&gt;&lt;P&gt;           x_error                    = 6&lt;/P&gt;&lt;P&gt;           enqueue_error              = 7&lt;/P&gt;&lt;P&gt;           OTHERS                     = 8&lt;/P&gt;&lt;P&gt;            .&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;P&gt;    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno&lt;/P&gt;&lt;P&gt;            WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ENDFORM.                    " SEND_MAIL&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 07 Sep 2006 13:03:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-email-from-the-report-program/m-p/1542633#M247087</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-09-07T13:03:57Z</dc:date>
    </item>
  </channel>
</rss>

