Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Write stack trace when an exception is thrown from another thread

Tags:

c#

.net

How can I write the stack trace of an unhandled exception (thrown from any thread) to a file?

I need this to help debug a hanging application.

like image 282
Niklaus Wirth Avatar asked Nov 27 '12 14:11

Niklaus Wirth


1 Answers

Take a look at AppDomain.UnhandledException event. It seems that this is exactly what you need.

like image 136
Sergey Teplyakov Avatar answered Oct 06 '22 09:10

Sergey Teplyakov