1 Reply Latest reply on Mar 5, 2006 12:32 PM by thomas.diesler

    Catching serverside custom Exceptions on clientside

    hinstance

      hi there,
      I am trying to build a webservice which throws custom exceptions to the client in case something goes wrong, e.g. a wrong password is given etc.
      I would like to catch these Exceptions directly on the client, without getting them out of the AxisFault which is wrapped around them, in the following manner:

      try
      {
      //make the webservice call
      ...
      } catch (InvalidPasswordException ivpe) {
      //do something with it
      ...
      } catch (UnknownUserException uue) {
      //do something with it
      ...
      }

      Is each and every Exception wrapped into an AxisFault or is there a way to get it to work in this way?
      It always comes up this way:

      -----------------------------------------------------------------------
      AxisFault
      faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Client
      faultSubcode:
      faultString: This is a test
      faultActor:
      faultNode:
      faultDetail:
      {}IstException:
      <message xsi:type="xsd:string">This is a test
      ------------------------------------------------------------------------

      Thanks for your help.


      with best regards,
      Dave