Programatic access to call stack in .net
-
08-06-2019 - |
Question
How can I get programmatic access to the call stack?
Solution
OTHER TIPS
You can use the StackTrace
and StrackFrame
classes in System.Diagnostics
.
The right way is to use the StackTrace
and StackFrame
classes. Throwing an exception just to get the stack trace is completely misusing exceptions.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow