Catch RFC Exception message text

Hi Experts,
I am calling a RFC from WebDynpro using adaptive RFC Model.
This RFC returns some Exception message along with the exception key from SAP R/3.
Like this :
MESSAGE e000(ztxx01) WITH 'this is exception message'
     RAISING table_not_available.
Now when i am trying to fetch this data in WebDynpro using the following statement:
msgmgr.reportException(ex.getLocalizedMessage(), false);
msgmgr.reportException(ex.getMessage(), false);
I can only see  TABLE_NOT_AVAILABLE .
How can i fetch the exception message thrown by RFC?
Regards,
Ashish Shah

Hi Ashish
you can't get the RFC-Messages directly (as i know).
You have to rebuild your
ABAP-Program that the errors will be redirected as a table.
There it gives a structure named 0_return (i don't know exactly) this is the standard table for outgoing error-messages.
Marco

Similar Messages

  • Adaptive RFC Exception Message Text

    Hi.
    How does one get the specific message text for an exception raised by the RFC? The given code in the tutorials only show the name of the exception, ie.
    catch (WDDynamicRFCExecuteException ex)
        manager.reportException(ex.<i>getMessage()</i>, false);

    Hi,
    getLocalizedMessage always retuns null and I actually don't know what to do with is but regarding the RFC error situation is following:
    1. If Model represent a BAPI then you have RETURN2 structure which contains STATUS and MESSAGE0 fields. The after invalidationg the output you can simply chek the status and if status is FAIL,ERROR or WARNING print the MESSAGE0 field using manager.reportMessage
    2. If RFC is not BAPI then all it's ABAP exception are maped to Java exception and ex.getMessage is best you can do.
    3.There are some RFCs which has their custom mechanism to report error in all sort of the output fields then you simply should check this field and print them in case they indicates the errors.
    Hope it helps.
    Victor.

  • How to populate the RFC .Exception Message Type?

    Hi All,
    I am invoking an RFC synchronously from PI.
    I am using the RFC.Exception message type to capture the exception raised from the RFC.
    In the RFC, I have created a Non-class based exceptino anf raising it using the "Raise" command.
    But it is only pupulating "Name" and "Text" of the Exception message. All other fileds are blank.
    Is their a special way to raise the excpetion in rfc so as to populate the Exceptoin message type in PI completely?
    thanks,
    Piyush

    But it is only pupulating "Name" and "Text" of the Exception message. All other fileds are blank.
    Did you follow the steps as mentioned in this blog: /people/jin.shin/blog/2007/05/21/handling-web-service-soap-fault-responses-in-sap-netweaver-xi
    Regards,
    Abhishek.

  • Catching RFC exception and "moving" it to soapenvlp:Fault.faultcode

    Hi,
    i have a simple SOAP2RFC (sync) interface. my question is:
    how can i catch an exception (thrown by RFC) and use it as soapenvlp:Fault.faultcode content?
    Regards
    Uri

    Hi!
    have a simple SOAP2RFC (sync) interface. my question is:
    how can i catch an exception (thrown by RFC) and use it as soapenvlp:Fault.faultcode content?
    Yes I think you can catch an exception by using RFC EXception (Fault) Message instead of RFC Response in the mappings. and remaining all steps are same.
    But that is mostly depends upon the RFC Function module that you are using and at which the logical coding of that Function module.
    [https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/18dfe590-0201-0010-6b8b-d21dfa9929c9]
    [https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/40574601-ec97-2910-3cba-a0fdc10f4dce]
    [https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/8c10aa90-0201-0010-98a0-f071394bc9ae]
    [http://help.sap.com/saphelp_nw70/helpdata/EN/44/2a41f420323f0ee10000000a114a6b/frameset.htm]
    [http://help.sap.com/saphelp_nw70/helpdata/EN/76/4a42f4f16d11d1ad15080009b0fb56/frameset.htm]
    Regards::
    Amar Srinivas Eli
    Edited by: Amar Srinivas Eli on Apr 8, 2009 8:44 PM

  • Catch RFC Exception - User Account locked

    Hello,
    I am hoping someone knows how in the portal to catch an exception thrown by JCo indicating a users account is locked in R/3. 
    I would like to trap the error and display a friendly error message to contact the correct people.  I do not want to see a Portal Runtime Error get presented to end users.
    Here is what it looks like in the default trace:
    Caused by: com.sap.mw.jco.JCO$Exception: (103) RFC_ERROR_LOGON_FAILURE: User is locked. Please notify the person responsible
    at com.sap.mw.jco.MiddlewareJRfc.generateJCoException(MiddlewareJRfc.java:418)
    Any docs on catching R/3 Fault exceptions is great as well.
    Thank you,
    Sean

    Usually when working with BAPIs, it is designed not to raise any exceptions.  They are designed to pass any errors back to the caller thru the BAPIRET2 parameter in the BAPI signature, using a TABLES parameter.  This is how you will let the user know gracefully.  If you are working with custom function modules which are to be called from the portal, they need to be developed in such a way that they do not RAISE and exceptions, but pass the errors back using a table like in the BAPIs.
    REgards,
    Rich Heilman

  • How to catch up Exception message?

    i have a question while using try{ ... }catch{ ... } clauses. for when update, delete, databse, there might be error occurred. all to often i do not deal with the message, only if to check log when serious problem i have to find it out; but i hope to learn how if i am able to display message of my own while erro occurrs. for instance, when falling into SQLException, originaly i might just utilize
    }catch(SQLException e){
    e.printStackTrace();
    is it possible for me to catch up message inside the printStackTrace that may happen while errors appearing? (or only down to catch{} clause be the last deadline that i am able to use? because i hope i am able to capture error code like ora-1234 and tranlate it into messages that user, who doesn't know too much about pc, can understand easily while reporting bug; and not just saying "we have problem here!")
    that is, if 'A' situation popping out, i hope to direct it to error page with special message shown. so does the same error page with different message specified while 'B' situation found out!
    any suggestions would be appreciated~
    thanks in advice,

    printStackTrace isn't obligatory. It's basically what you do with an exception when you don't have anything more specific to do with it.
    You can certainly catch a specific exception at any level, including inside another try {} block.
    Even having caught an exception you can decide that you don't want to handle it at this point in the code, and throw it again.
    You might do:
    try {
         try {
           ... statment which migh cause a particular database exception
            } catch(SQLException e) {
            if(e.getMessage().startsWith("ORA-1232")) {
              .. do somthing usefull
             } else
            throw e;   // the particular SQL exception was unexpected so go on and crash
       catch(Exception e) {
         e.printStackTrace();   // unexpected program failure

  • How to Extract Error Text from RFC.Exception within BPM?

    Hi,
    I have a scenario MPA -> XI <-> RFC.  A synchronous RFC call will be performed inside a BPM on a SAP system.  An exception message is expected if RFC raises exception.  However, there don't seem to be any mechanism that allows logic/step in BPM to extract the error text from the RFC exception message in order to send it out to user as an error alert.
    Appreciate if anyone can shed some lights.  Thx in advance.
    Regards
    Chong Wah

    Hi,
    you can always wrap your RFC with another one
    in which you'll catch the exception
    and pass in a normal field back to the XI
    and then do the standard as per my weblog:
    /people/michal.krawczyk2/blog/2005/03/13/alerts-with-variables-from-the-messages-payload-xi--updated
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • Catching System Error Message in Abap Proxy.

    Hi all,
        I want to know whether it is possible to catch the system error message from SXMB_MONI in proxy scenario's.
        The error i am getting is :
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Adapter
      -->
    - <SAP:Error xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/" SOAP:mustUnderstand="1">
      <SAP:Category>XIServer</SAP:Category>
      <SAP:Code area="INTERNAL">HTTP_RESP_STATUS_CODE_NOT_OK</SAP:Code>
      <SAP:P1>403</SAP:P1>
      <SAP:P2>Forbidden</SAP:P2>
      <SAP:P3 />
      <SAP:P4 />
      <SAP:AdditionalText>Service is not active</SAP:AdditionalText>
      <SAP:ApplicationFaultMessage namespace="" />
      <SAP:Stack>HTTP response contains status code 403 with the description Forbidden Error when sending by HTTP (error code: 403, error text: Forbidden)</SAP:Stack>
      <SAP:Retry>N</SAP:Retry>
      </SAP:Error>
    Is it possble to catch the above message text.
    Regards,
    Keith

    Hi Keith,
    Check this forums also should be definitely help u..
    Error message handling in Integration Process
    and
    http://help.sap.com/saphelp_nw04/helpdata/en/dd/b7623c6369f454e10000000a114084/content.htm
    also refer
    Check this weblog once ... sure it will give u an idea..
    /people/sap.user72/blog/2006/01/16/xi-propagation-of-meaningful-error-information-to-soap-client
    and also go through this
    /people/alessandro.guarneri/blog/2006/01/26/throwing-smart-exceptions-in-xi-graphical-mapping
    Regards,
    Sridhar

  • Message text available in java using RFC function module

    Hello,
    I wrote a function module with the ABAP statement
    MESSAGE .... RAISING PARAMETER_ERROR
    The java developer gets the PARAMETER_ERROR but no
    message text.
    Is the any way (e.g. exception class) to get the message text also.
    Thanks

    hi Michael,
    In the RFC function module use the table RETURN of type BAPIRET2 and instead of raising the error append the error in RETURN. later in your java code you can read this table RETURN and retrieve the error along with the error text.
    Hope this helps.
    Regards,
    Richa.

  • SOAP Runtime: Exception message: Unallowed RFC-XML Tag (SOAP_EINVALDOC)

    Hi,
    Curretly I am trying to test a Webservice on ECC 5.0, Oracle, Windows.
    Below is the error that I am facing.
    SOAP Runtime: SOAP Runtime exception: 111 occurred in method XP_READ_TAG of class CL_SOAP_XP at position 1
    SOAP Runtime: Exception message: Unallowed RFC-XML Tag (SOAP_EINVALDOC)
    In dev_rfc0:
    ERROR 03:20:57: SOAP HTTP Binding CL_SOAP_HTTP_TPBND_ROOT->HANDLE
    STATUSCODE() Received return code 404 ( Not found )
    ERROR 03:20:57: SOAP Message CL_SOAP_MESSAGE->IF_SOAP_MESSAGE
    PART~INITFOR_DESERIALIZE() A SOAP Runtime Core Exception
    occurred in method XP_READ_TAG of class CL_SOAP_XP at position id
    1 with internal error id 111 and error text Unallowed RFC-XML Tag
    (SOAP_EINVALDOC) (fault location is 1 ).
    I have looked up on sdn, and also looked at note 919886.
    I have read several posts regarding creation of RFC Destination in sm59 of Type G, to get over this issue.
    But RFC Destination of type G is not available in ECC 5.0
    Is the error because of incorrect URL mentioned in logical port,
    I am unable to ping the host name mentioned in URL, looks like that machine is not in the network.
    does it mean the wsdl is not located at that particular host.
    Any suggestions would be greatly appreciated.
    Regards,
    Vishnu.

    Hi Anton,
    The complete error message in dev_rfc0:
    INFO 02:15:12: SOAP Transport Binding CL_SOAP_HTTP_TPBND_ROOT
    ->IF_SOAP_TRANSPORT_BINDING~SEND() Try to send message ( DEST =
    ,PATH = ,URL = http://hostname:portno/ ,SOAP Action =
    "ROI_R3_DF.roiSAPCreateOrder" )
    INFO 02:15:12: SOAP Transport Binding CL_SOAP_HTTP_TPBND_ROOT
    ->IF_SOAP_TRANSPORT_BINDING~SEND() Message sent
    INFO 02:15:12: SOAP Transport binding CL_SOAP_HTTP_TPBND_ROOT
    ->IF_SOAP_TRANSPORT_BINDING~RECEIVE() Try to receive message
    ERROR 02:15:12: SOAP HTTP Binding CL_SOAP_HTTP_TPBND_ROOT->HANDLE
    STATUSCODE() Received return code 404 ( Not found )
    ERROR 02:15:12: SOAP Message CL_SOAP_MESSAGE->IF_SOAP_MESSAGE
    PART~INITFOR_DESERIALIZE() A SOAP Runtime Core Exception
    occurred in method XP_READ_TAG of class CL_SOAP_XP at position id
    1 with internal error id 111 and error text Unallowed RFC-XML Tag
    (SOAP_EINVALDOC) (fault location is 1 ).
    After reading your post about the return code 404, I am in a dilemma whether, services in icman are unavailable or
    the services at the location of the wsdl in the other server.
    If you could clarify, it would be great.
    Thanks a lot.
    Vishnu.

  • As I bought my iPhone 5 16GB,White in the USA from Sprint, full price with tax,unlocked ,it was excepted to be a global phone. But now I come across with some problems in Chinausing local carrier, everything is working properly except sending text message

    Dear AppleCare,
    As I bought my iPhone 5 16GB,White in the USA from Sprint, full price with tax,unlocked ,it was excepted to be a global phone. But now I come across with some problems in Chinausing local carrier, everything is working properly except sending text message, and iMessage and Facetime also seem not to work.This is very serious for Apple and me! Will I have the chance to fix this?
    I tried all the possible solutions from the Internet, and the Official solution offered by Apple (http://support.apple.com/kb/TS4459), but it doesn't seem to work.
    Will Apple help me with this issue? Please do.
    Information of my iPhone:
    SN:F1*******8GJ
    IMEI: ****
    MEID: ****
    ICCID: ****
    My Apple ID account:****
    <Personal Information Edited By Host>

    I had the same problem.  Kept getting message of waiting for activation or check network connections.  I also tried every solution out there and nothing worked.  This did though:  I download the newest version of itunes (through Internet Explorer - Google Chrome wouldn't work).  It pulled in my entire library thank goodness and then I plugged my iphone 4s into the computer.  I let itunes find it, did a complete backup in icloud, then did a restore.  Entire process took a couple of hours, but I now have imessage and facetime back.  I was about ready to give up on Apple and go get a different phone ~

  • RFC Exception COMMUNICATION_FAILURE with Message RFC destination RFC does n

    Hi all , i did a small application in webdynpro abap  by calling BAPI . MY application  is when i enter the studentid and click the submit button i shoutl get student details .
    but when i'm clicking the submit button i'm gettting the error
    "RFC Exception COMMUNICATION_FAILURE with Message RFC destination RFC does not exist. Occurred " can any one help me out.

    hi rajeev.....
        i am sure that you would have used service call.
       in service call, in the destination part, you would have given a name. the service call automatically creates a destination in this name. but your user id would not have had that rights. so only you get this error. either use a already existing destination or get the access for that.
    ---regards,
       alex b justin

  • Catch any error message (dumps) in B2B and show own text

    Hi, all
    How we can catch any error messages (dumps) in the B2B?
    How we can show own text like this 'Site under construction. Please visit later...after 1 hour... '
    Denis

    Option 1(dirty approach): modify your runtimeexception jsp
    Option 2(better approach): on your load balancer (like F5 or SAP web dispatcher) configure such that all HTTP500 response codes are redirected to a hub page which has your custom text or images
    pradeep

  • Resend message after catching JMS Exception

    Hi,
    If i resend message after catching JMS Exception is there any chance that the message will be send to the destination queue? (without reconnecting to the queue).
    thanks!

    The problem is you don't really know if its already been sent or not. Then if the broker's gone down you need to recreate your connection, sessions, producers, consumers etc.
    Its much easier to just use a JMS provider which supports auto-reconnection for you which totally hides and fixes all these problems
    http://activemq.apache.org/how-can-i-support-auto-reconnection.html
    James
    http://logicblaze.com/
    Open Source SOA

  • Get Exception Information from RFC Response Message

    Hi All,
    I want to make RFC call from ABAP system to XI RFC Adapter. I found that on the caller side, the RFC has the following interface for RFC exception.
    Exception
    __Name
    __Text
    __Message
    ____ID
    ____Number
    __Attributes
    ____V1
    ____V2
    ____V3
    ____V4
    Can anybody tell me how to get the info contained by this exception structure from RFC caller side (ABAP program)?
    Thanks, Jerome

    Hi Madan,
    My problem is how to display the exception information on the caller side. The called side is able to throw exception now.
    Thanks, Jerome

Maybe you are looking for

  • Report Painter / resources committed

    Gurus, I need your help. Getting in report painter committed resources released purchase requisitions. If I was not clear, sorry and I can give more details.

  • Losing Calendar info between syncs

    I use the Palm Z22.  I am on Windows Vista OS.  I sync regularly and save on my PC regularly.  Periodically, after rebooting, when I open Palm, almost all (but not all, and I haven't figured out the pattern) of my dated/timed events are missing.  I t

  • Screenshare protocol question...

    Does screenshare treat the screen like a normal video stream? Or does it use the RFB protocol?

  • Financial Reports Datasources and Models

    Hi,gurus here. What's the datasource and popular model of Balance Sheet,Income Statement/P&L,Cash Flow statements,Changes in Equity sheet? Thanks.

  • Another N80 Problem!

    Hi - okay found this other problem when reading emails and sometimes writing or reading texts, as soon as you scroll down to read or write these messages, the first 1 and 1/2 letters of a line dissapear!! yes thats right, 1 and 1/2 characters vanish!