<?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 Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1 in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181580#M1518582</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Your HTML and formatting is probably wrong then, but without posting any code, no one is going to be able to tell you the issue...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 02 Sep 2010 16:02:54 GMT</pubDate>
    <dc:creator>brad_bohn</dc:creator>
    <dc:date>2010-09-02T16:02:54Z</dc:date>
    <item>
      <title>Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181569#M1518571</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I using the FM &lt;STRONG&gt;SO_NEW_DOCUMENT_SEND_API1&lt;/STRONG&gt; to send mail to the managers regarding his subordinates time sheets.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have concatenated different variables in to work area of &lt;STRONG&gt;object_content&lt;/STRONG&gt; by keeping 'Concatenate respecting Blanks'.&lt;/P&gt;&lt;P&gt;So I am getting blanks also perfectly formatted.&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;In this way I am filling the internal table object_content successfully, with all the required spaces necessary.&lt;/P&gt;&lt;P&gt;In debugging I can see that the table object_content  is perfectly formatted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But in the mail the format is missing, There I am getting unbelievable gaps, depending upon the data I am inserting into &lt;/P&gt;&lt;P&gt;the table Object_Content.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have supplied the Document Size also perfectly in the Object_Header.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any thing more to do to achieve correct formating, (ie As it is was in the table object_content)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards&lt;/P&gt;&lt;P&gt;Avinash&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 01 Sep 2010 16:42:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181569#M1518571</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-01T16:42:55Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181570#M1518572</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use HTML and table tags, not to mention class CL_BCS if you have it available.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 01 Sep 2010 18:19:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181570#M1518572</guid>
      <dc:creator>brad_bohn</dc:creator>
      <dc:date>2010-09-01T18:19:29Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181571#M1518573</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Brad&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I didn't exactly got what you are saying. Can you please elaborate.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards&lt;/P&gt;&lt;P&gt;Avinash&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 12:22:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181571#M1518573</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-02T12:22:40Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181572#M1518574</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use HTML to format your email body instead of plain text with spaces.  HTML tables are a far easier and more precise way to format text positioning, not to mention the other options you have with design elements to make your emails user friendly and professional looking.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are on NW 6.0 or higher, stop using the email function and start using the CL_BCS class.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 12:54:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181572#M1518574</guid>
      <dc:creator>brad_bohn</dc:creator>
      <dc:date>2010-09-02T12:54:07Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181573#M1518575</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Now I have used the CL_BCS Class also, But the same issue is coming.&lt;/P&gt;&lt;P&gt;I have populated all my data in to text of the example BCS_EXAMPLE_4.&lt;/P&gt;&lt;P&gt;and used the same code as it was in BCS_EXAMPLE_4 (to mail a sapuser).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But still the problem is existing.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 14:16:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181573#M1518575</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-02T14:16:49Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181574#M1518576</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Again, use HTML...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 14:20:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181574#M1518576</guid>
      <dc:creator>brad_bohn</dc:creator>
      <dc:date>2010-09-02T14:20:27Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181575#M1518577</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use the following method to get rid of the error:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Convert the text string into UTF-16LE binary data including&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;byte-order-mark. Mircosoft Excel prefers these settings&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;all this is done by new class cl_bcs_convert (see note 1151257)&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  TRY.&lt;/P&gt;&lt;P&gt;      cl_bcs_convert=&amp;gt;string_to_solix(&lt;/P&gt;&lt;P&gt;        EXPORTING&lt;/P&gt;&lt;P&gt;          iv_string   = lv_string&lt;/P&gt;&lt;P&gt;          iv_codepage = '4103'      "suitable for MS Excel, leave empty for other doc types&lt;/P&gt;&lt;P&gt;          iv_add_bom  = 'X'&lt;/P&gt;&lt;P&gt;        IMPORTING&lt;/P&gt;&lt;P&gt;          et_solix  =  binary_content&lt;/P&gt;&lt;P&gt;          ev_size   = size ).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    CATCH cx_bcs.&lt;/P&gt;&lt;P&gt;  ENDTRY.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can refer to the program BCS_EXAMPLE_7 for more info.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 14:23:30 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181575#M1518577</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-02T14:23:30Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181576#M1518578</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can You tell me how to use HTML? Can you give me any sample program or like to go with HTML.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 14:24:09 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181576#M1518578</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-02T14:24:09Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181577#M1518579</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;PRE&gt;&lt;CODE&gt; CALL FUNCTION 'SO_NEW_DOCUMENT_SEND_API1'
    EXPORTING
    document_data                     =  doc_chng
     document_type                    = 'HTM'&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And use normal html Tags for formatting.(Space, bold.....)&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 14:26:32 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181577#M1518579</guid>
      <dc:creator>Dasig</dc:creator>
      <dc:date>2010-09-02T14:26:32Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181578#M1518580</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can You tell me how to use HTML? Can you give me any sample program or like to go with HTML.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Sorry, this is not a training site for basics.  Any examples that I have are macro-based for re-usability and would probably not make sense to you.  A good developer should be familiar with HTML - there are many sites on the internet that have tutorials.  For tables, focus on the &amp;lt;table&amp;gt;, &amp;lt;tr&amp;gt;, and &amp;lt;td&amp;gt; tags.  Maybe Thomas or someone else has blogged about it...search SDN as well.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 14:43:07 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181578#M1518580</guid>
      <dc:creator>brad_bohn</dc:creator>
      <dc:date>2010-09-02T14:43:07Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181579#M1518581</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have Tried The HTML Tags also.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In debugging I can see the text table filled with blanks if data is not there in a concatenated variable &lt;/P&gt;&lt;P&gt;and then I have used  &lt;STRONG&gt;span style="padding-left:20px&lt;/STRONG&gt;  to put space between two columns.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In debugging it is all fine and while mail comes it is deleting the empty spaces of the concatenated variable.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 15:41:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181579#M1518581</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-02T15:41:47Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181580#M1518582</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Your HTML and formatting is probably wrong then, but without posting any code, no one is going to be able to tell you the issue...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Sep 2010 16:02:54 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181580#M1518582</guid>
      <dc:creator>brad_bohn</dc:creator>
      <dc:date>2010-09-02T16:02:54Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181581#M1518583</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;CONCATENATE: '&amp;lt;P&amp;gt;'
        wa_managers_copy-pernr
                  '&amp;lt;span style="padding-left:20px"&amp;gt;'
                     wa_managers_copy-pernr_name
                     '&amp;lt;span style="padding-left:20px"&amp;gt;'
                     wa_managers_copy-pernr_kostl
                     '&amp;lt;span style="padding-left:20px"&amp;gt;'
                     wa_catsdb-workdate
                     '&amp;lt;span style="padding-left:20px"&amp;gt;'
                     string
                     '&amp;lt;P&amp;gt;'
                     INTO wa_object_content-line
                     SEPARATED BY space
                                          RESPECTING BLANKS.
        APPEND: wa_object_content TO it_object_content[].
        APPEND: wa_object_content TO text.

 w_cr_lf = cl_abap_char_utilities=&amp;gt;cr_lf.

      LOOP AT text INTO wa_text.
        CONCATENATE w_data wa_text w_cr_lf INTO w_data.
        CLEAR wa_text.
      ENDLOOP.
w_size = '5000'.
      TRY.
          cl_bcs_convert=&amp;gt;string_to_solix(
          EXPORTING
          iv_string = w_data
          iv_codepage = ''
          iv_add_bom = '' "for other doc types
          IMPORTING
          et_solix = it_bin_data
          ev_size = w_size ).
        CATCH cx_bcs.
*          p_fail = 'X'.
      ENDTRY.

      TRY.
          send_request = cl_bcs=&amp;gt;create_persistent( ).
          document = cl_document_bcs=&amp;gt;create_document(
                          i_type    = 'HTM'
*                          i_text    = text
                          i_hex    = it_bin_data
                          i_length  = '5000'
                          i_subject = 'test created by BCS_EXAMPLE_3' ).
          CALL METHOD send_request-&amp;gt;set_document( document ).
          sender = cl_sapuser_bcs=&amp;gt;create( sy-uname ).
          CALL METHOD send_request-&amp;gt;set_sender
            EXPORTING
              i_sender = sender.
          recipient = cl_sapuser_bcs=&amp;gt;create( i_user = 'MNGR02' ).
          CALL METHOD send_request-&amp;gt;add_recipient
            EXPORTING
              i_recipient = recipient
              i_express   = 'X'.
          CALL METHOD send_request-&amp;gt;send(
            EXPORTING
              i_with_error_screen = 'X'
            RECEIVING
              result              = sent_to_all ).
          IF sent_to_all = 'X'.
            WRITE text-003.
          ENDIF.

          COMMIT WORK.&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Sep 2010 11:35:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181581#M1518583</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-03T11:35:13Z</dc:date>
    </item>
    <item>
      <title>Re: Send Mail: Formatting Error: SO_NEW_DOCUMENT_SEND_API1</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181582#M1518584</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The above is the Code I have written.&lt;/P&gt;&lt;P&gt;I have Tried with Binary Data Also using HTML Tags Correctly.&lt;/P&gt;&lt;P&gt;Please let me know if there is any problem in the Code Written.&lt;/P&gt;&lt;P&gt;I couls not able to understand the issue.&lt;/P&gt;&lt;P&gt;When I Trigger the same mail to internet address, that is Receiver type 'U' , It is going with correct format.&lt;/P&gt;&lt;P&gt;But here I am sending mail to SAPUSER, So here I am getting problem in the format.&lt;/P&gt;&lt;P&gt;Will the Tcode SBWP will show the data like that only or will there be any furthur things to be followed to send a mail &lt;/P&gt;&lt;P&gt;to SAPUSER.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards&lt;/P&gt;&lt;P&gt;Avinash&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Sep 2010 11:36:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/send-mail-formatting-error-so-new-document-send-api1/m-p/7181582#M1518584</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2010-09-03T11:36:04Z</dc:date>
    </item>
  </channel>
</rss>

