# Get details of thrown BPMN Error

**URL:** <https://forum.flowable.org/t/get-details-of-thrown-bpmn-error/1863>\
**Category:** Flowable Engine\
**Created:** [April 10, 2018, 10:06am UTC](https://forum.flowable.org/t/get-details-of-thrown-bpmn-error/1863 "2018-04-10T10:06:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![aman](https://avatars.discourse-cdn.com/v4/letter/a/90ced4/32.png) [@aman](https://forum.flowable.org/u/aman)\
**Post date:** [April 10, 2018, 10:06am UTC](https://forum.flowable.org/t/get-details-of-thrown-bpmn-error/1863/1 "2018-04-10T10:06:27Z")

</div>

Hi,

I am throwing a BPMN Error from a delegate. While throwing that error, I am passing a descriptive message with the error code (as constructor allows to provide message along with error code). I have an event based sub-process to catch that error. This process is supposed to take the message from error and put it in a log file.

I am not sure about how to retrieve the message from the error in the sub-process. So I would like get some input on how to accomplish that.

Thanks in advance,  
Aman Shrivastava

---

<div class="post-metadata">

**Author:** ![wberges](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.flowable.org/wberges/32/940_2.png) [@wberges](https://forum.flowable.org/u/wberges)\
**Post date:** [March 27, 2019, 10:39am UTC](https://forum.flowable.org/t/get-details-of-thrown-bpmn-error/1863/2 "2019-03-27T10:39:12Z")

</div>

Hello,  
I have the same question, without answer also 🙂  
The only way I have found to have additional info about the error is to add variable(s) to the execution context before throwing the BPMNError, then to get them in the error flow.  
E.g.

> execution.setVariable(“errorMessage”, myErrorMessage);

Has anybody another way to retrieve error message?  
Thanks  
William
