Throw an error from an OpenEdge UI trigger to the main program

Discussão em 'StackOverflow' iniciado por fdantas, Dezembro 7, 2016.

  1. fdantas

    fdantas Administrator Moderador

    I'm struggling to propagate an system error object from a UI trigger to the main program.

    ON CHOOSE OF btnButton IN FRAME frmFrame
    DO:

    /* this will cause a system error */
    FIND FIRST Customer NO-LOCK
    WHERE Customer.CustNum = 1875918759178.

    CATCH eErr AS Progress.Lang.SysError:
    /* It does get caught over here */
    UNDO, THROW eErr.
    END CATCH.
    END.

    CATCH eMain AS Progress.Lang.SysError:
    /* this message doesn't happen */
    MESSAGE
    "caught"
    VIEW-AS ALERT-BOX.
    END CATCH.


    It doesn't seem to want to propagate the error object though. Any ideas?

    Continue reading...

Compartilhe esta Página