<?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 capture error messages from CLASS cx_document_bcs in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720045#M1579980</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;I am using the class CL_BSC for sending mail with attachment,i need to disply the messge captured in the cx_document_bcs in spool log.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  TRY.
      lo_document-&amp;gt;add_attachment(
      EXPORTING
      i_attachment_type = 'PDF'
      i_attachment_subject = 'Test*      
      i_attachment_subject = i_attachment_subject1
      i_att_content_hex = lt_att_content_hex ).
    CATCH cx_document_bcs INTO lx_document_bcs.
  ENDTRY.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How to disply the messges in Spool,which are captured in the cx_document_bcs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please advise.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Kiran&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 09 Mar 2011 21:11:40 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2011-03-09T21:11:40Z</dc:date>
    <item>
      <title>capture error messages from CLASS cx_document_bcs</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720045#M1579980</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;I am using the class CL_BSC for sending mail with attachment,i need to disply the messge captured in the cx_document_bcs in spool log.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;  TRY.
      lo_document-&amp;gt;add_attachment(
      EXPORTING
      i_attachment_type = 'PDF'
      i_attachment_subject = 'Test*      
      i_attachment_subject = i_attachment_subject1
      i_att_content_hex = lt_att_content_hex ).
    CATCH cx_document_bcs INTO lx_document_bcs.
  ENDTRY.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How to disply the messges in Spool,which are captured in the cx_document_bcs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please advise.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Kiran&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Mar 2011 21:11:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720045#M1579980</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-03-09T21:11:40Z</dc:date>
    </item>
    <item>
      <title>Re: capture error messages from CLASS cx_document_bcs</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720046#M1579981</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kiran,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Catch exceptions like this.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
TRY.
...
 CATCH cx_document_bcs INTO lx_document_bcs.
     MESSAGE Ennn(ZXX).
CLEANUP.
ENDTRY.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There  you can check diffrent exceptions like this.. from class CX_DOCUMENT_BCS..&lt;/P&gt;&lt;P&gt;ERROR_TYPE parameter of lx_document_bcs contains the below values.. or you can use message parameters. Check constructore parameters in that class.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OBJECT_NOT_EXISTS&lt;/P&gt;&lt;P&gt;KPRO_ERROR&lt;/P&gt;&lt;P&gt;MIME_NOT_AVAILABLE&lt;/P&gt;&lt;P&gt;Based on the code you can give meaning ful message.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Mar 2011 21:23:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720046#M1579981</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-03-09T21:23:28Z</dc:date>
    </item>
    <item>
      <title>Re: capture error messages from CLASS cx_document_bcs</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720047#M1579982</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Catch the exceptions as descibed.  send messages to spool with Messase ststement.  Eg, message sooo(za) with 'no records found'.  That message will show up in job log.   Any write statement will show up in the spool.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Mar 2011 05:57:46 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720047#M1579982</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-03-10T05:57:46Z</dc:date>
    </item>
    <item>
      <title>Re: capture error messages from CLASS cx_document_bcs</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720048#M1579983</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;
data:lf_ref type ref to cx_root.
data:lf_string type string.

TRY.
      lo_document-&amp;gt;add_attachment(
      EXPORTING
      i_attachment_type = 'PDF'
      i_attachment_subject = 'Test*      
      i_attachment_subject = i_attachment_subject1
      i_att_content_hex = lt_att_content_hex ).
    CATCH cx_root INTO lf_ref.
    lf_string = lf_ref-&amp;gt;get_text( ).
     MESSAGE E101(ZMM) with lf_string.
  ENDTRY.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Mar 2011 11:23:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/capture-error-messages-from-class-cx-document-bcs/m-p/7720048#M1579983</guid>
      <dc:creator>kesavadas_thekkillath</dc:creator>
      <dc:date>2011-03-10T11:23:18Z</dc:date>
    </item>
  </channel>
</rss>

