IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

Accessing errorText within a Catch block

  • 1.  Accessing errorText within a Catch block

    Posted Thu February 28, 2002 10:27 AM

    Is there an easy way to access the errorText of the errorNotify that is caught in the Catch block within the Enterprise Integrator? Can I catch only some exceptions (and pass others)?

    Enterprise 4.1.1, Tools 4.5.1, on Win2k.


    #webMethods
    #Adapters-and-E-Standards
    #Integration-Server-and-ESB


  • 2.  RE: Accessing errorText within a Catch block

    Posted Tue March 12, 2002 09:11 AM

    What you need to do is declare a private member variable at the top of the integration script. Then in the script under the try-catch you write to that variable:

    try {
    catchStepTry();
    }
    catch (AdapterException catchStepEx) {
    someStringVariable = catchStepEx.toString();
    catchStepCatch();
    }

    then use a custom step to return someStringVariable. You can only catch AdapterException exceptions within the try-catch. So if you have a custom step within the try-catch and it throws a null pointer exception, it will not be caught.


    #Adapters-and-E-Standards
    #Integration-Server-and-ESB
    #webMethods