Is there a way to see the methods call stack of an application while its running? I have a thrid party application which is not working correctly and I would like to see what methods are being called in what order? Are there any simple tools for that? I couldnt find much in google except ants performance profiler but that is overwhelming my issue and it coasts something
Asked
Active
Viewed 93 times
0
-
possible duplicate of [How to print the current Stack Trace in .NET without any exception?](http://stackoverflow.com/questions/531695/how-to-print-the-current-stack-trace-in-net-without-any-exception) – Royi Namir Sep 10 '15 at 10:59
-
Only near dupe imo. It should definitely be linked though. – Heki Sep 10 '15 at 11:15
-
i do not have the source code, thats the problem, i need an external tool – dev hedgehog Sep 10 '15 at 11:27
3 Answers
0
You can use PerfView, which is free and can take snapshots of the stacks as the application is running. Sometimes these stacks are incomplete as there is not enough symbol information, but I have had great success using that on production machines where I was unable to instrument the application.

NeddySpaghetti
- 13,187
- 5
- 32
- 61
0
You can use jetbrains tools:
https://www.jetbrains.com/profiler/help/Call_Stack.html
https://www.jetbrains.com/resharper/documentation/help20/Navigation/stackTraceExplorer.html
Hope these will help :)

Awn Ali
- 1,361
- 1
- 17
- 31
0
If you can do it from C#
code it should be enough to use StackTrace
class and inspect StackFrame
collection
var stackTrace = new StackTrace();
var frames = stackTrace.GetFrames();
foreach(var frame in frames)
{
var methodDescription = frame.GetMethod();
Console.WriteLine(methodDescription.Name);
}
There are also other helpful properties in the frame like file name / number / lines etc.

tchrikch
- 2,428
- 1
- 23
- 43