19

OK, this is a silly question, but when using Visual Studio, if I am writing XML doc comments in Visual Basic, I can use the tab key to switch between fields (e.g. Summary to Param to Returns). In C#, however, hitting the Tab key inserts a Tab, so I have to click on the individual fields to navigate to them (or use the arrow keys). This makes what should have been a simple process tedious and time-consuming.

Anybody know if there is a default keyboard shortcut I can use, or if there is a specific command I can map to an unused keyboard shortcut? I am using Visual Studio 2010, with ReSharper 6.1. Did some searching in the SO archives, but either nobody else has this problem, or I don't know the right keywords to ask (the latter is much more likely). Thanks in advance!

EDIT: I should clarify, a bit. The tabbing behavior in VB is native to Visual Studio 2010; the ReSharper install is fairly recent (after I switched to C#), and I wanted to mention it in case someone might know whether ReSharper had added their own navigation shortcuts (as they have tons) for this. Thanks again!

4

2 回答 2

2

Resharper 确实具有结构导航的可能性。通常,您可以使用TabShift+Tab快捷键转到下一个或上一个代码元素。如果您的光标位于代码元素中(即不在代码行之前的空白区域中),则Tab键不应插入选项卡,而是导航到下一部分。结构导航的配置可以在Environment|Editor|Editor Behavior中完成。

如果它仍然无法按描述工作,我会尝试重置设置(尤其是 Resharper 的设置)并检查 Resharper 是否安装正确。

于 2017-03-14T15:31:31.420 回答
0

我可能误解了这个问题,但也许听起来您可以重置您的用户设置? http://msdn.microsoft.com/en-us/library/ms247075%28v=vs.100%29.aspx?或者只是运行 devenv / resetuserdata 。这样做,当你启动 Visual Studio 时,也许选择“常规”设置而不是 C# 或 vb.net 特定的设置?

于 2012-06-28T04:46:12.533 回答