Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the purpose of the Call Stack window in Visual Studio?

What is the purpose of the Call Stack window in Visual Studio?

like image 555
eomeroff Avatar asked Aug 18 '10 13:08

eomeroff


1 Answers

When your code breaks (i.e., when an exception is thrown) the Stack Trace Window will show you all methods that have been called prior to the method that raised the exception, including the parameters for each method and the state of these parameters. This makes debugging easier, especially in more complex call graphs (that is, when you cannot determine by looking at your code who called what other method/property/function).

Just try it, place a breakpoint somewhere in your code (F9), run your code, wait for the breakpoint to be hit and then open the stack window. You'll see all calls up to the current line. You can double click each entry in the stack trace window and the cursor will jump right at it.

In case you wondered: gray lines are method calls of which no source code, or symbols are loaded. You can rightclick these lines and select Load Symbols to load the symbols.

like image 81
Abel Avatar answered Sep 30 '22 11:09

Abel