We have a large application that has currently his own exception handling solution.
Now we would like to extend error tracing specially we need to add call stack in case of error. This should run in the background without affecting the user interface.
All error logs shall be send to our already existing reporting system.
How could i realize such a solution using madExcept?
(1) disabling the "show please wait box" here:
(2) settings the bottom right combobox to "don't show anything" here:
You may also want to disable automatic bug report saving and sending here:
The next thing you need to do is install your own little exception handler. You can do this by using the following code:
Code: Select all
uses ..., madExcept; procedure YourExceptionHandler(const exceptIntf: IMEException; var handled: boolean); begin SendBugReportToYourOwnReportingSystem(exceptIntf.BugReport); handled := true; end; initialization RegisterExceptionHandler(YourExceptionHandler, stDontSync, epCompleteReport); end.
Please note that when using the parameter "stDontSync" your exception handler will be called in the context of a secondary thread. That means your code must be thread safe and must not use any VCL stuff (like showing VCL windows etc).