How can I navigate the call stack in Visual Studio

2020-06-01 07:28发布

My current solution is to hit AltD, W, C, which navigates via the menus to the call stack, and then I can use the arrows to navigate. But once I press Enter on a particular frame, I have to repeat again.

Is there a more fluid way to navigate the call stack with just my keyboard?

ReSharper oriented answers are OK for me if you have one!

3条回答
男人必须洒脱
2楼-- · 2020-06-01 07:33

Call Stack view in Visual Studio can be brought up with Ctrl+Alt+C or Alt+7. That allows navigating the stack with and as well as performing "Switch To Frame" action with Enter⏎.

Unfortunately, switching to a frame moves focus to the editor window, so the above sequence of actions has to be done again if you want to switch to another frame.

查看更多
手持菜刀,她持情操
3楼-- · 2020-06-01 07:36

I use the VS2010 default keyboard mapping scheme and by pressing Ctrl+Alt+C brings up the call stack window in which I can use the arrow keys to navigate.

The macro name is Debug.CallStack

查看更多
一纸荒年 Trace。
4楼-- · 2020-06-01 07:47

Here is a dorky AutoHotkey script that will navigate up and down the call stack using CtrlAltNumPadUp and CtrlAltNumPadDown.

SetTitleMatchMode 2 ; Allow for partial matches in window titles
#IfWinActive, (Debugging) ; Only work while VS is debugging
  ^!Numpad2:: ; Navigate down Call Stack in Visual Studio
    Send ^!c
    Send {Down}
    Send {Enter}
  return
  ^!Numpad8:: ; Navigate up Call Stack in Visual Studio
    Send ^!c
    Send {Up}
    Send {Enter}
  return
#IfWinActive
查看更多
登录 后发表回答