需要热键/按钮来注释 Visual Studio 2008 Express 中的代码块
我来自 Eclipse,在 Visual Studio 2008 Express 中工作,只想突出显示代码,右键单击并将其注释掉。
- 右键
- 单击“工具”| 中 没有任何内容 选项、工具栏、命令,找不到它的按钮...
如何激活注释/取消注释功能,我知道 Visual Studio 2003 有它。
答案如下,结果取决于您使用的是什么:
Visual Studio 2008 完整版:
Comment Ctrl-K , Ctrl -C
取消注释 Ctrl-K 、 Ctrl-U
Visual Web Developer 2008 Express:
注释Ctrl-K、Ctrl-C
取消注释 Ctrl-K 、 Ctrl-U
Visual C# 2008 Express:
注释 < kbd>Ctrl-E , Ctrl-C
取消注释 Ctrl-E 、 Ctrl-U
I'm coming from Eclipse, working in Visual Studio 2008 Express and just want to highlight code, right-click and comment it out.
- nothing in right-click
- looking in Tools | Options, Toolbars, Commands, can't find a button for it...
How do I activate this the comment/uncomment feature, I know Visual Studio 2003 had it.
HERE ARE THE ANSWERS, TURNS OUT IT DEPENDS WHAT YOU ARE USING:
Visual Studio 2008 Full Version:
Comment Ctrl-K , Ctrl-C
Uncomment Ctrl-K , Ctrl-U
Visual Web Developer 2008 Express:
Comment Ctrl-K , Ctrl-C
Uncomment Ctrl-K , Ctrl-U
Visual C# 2008 Express:
Comment Ctrl-E , Ctrl-C
Uncomment Ctrl-E , Ctrl-U
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(4)
奇怪的是 Ctrl+E、C(注释)和 Ctrl+E, U(取消注释)
通常是Ctrl+K,C 和 Ctrl+K、U 正如 Mauro 所说。 Express Edition 默认(且唯一)键盘映射另有说明。
Weird it's Ctrl+E, C (Comment) and Ctrl+E, U (Uncomment)
Normally It's Ctrl+K, C and Ctrl+K, U as Mauro says. Express Edition default (and only) keyboard mapping says otherwise.
组合键
注释 Ctrl-K , Ctrl-C
取消注释 Ctrl-K , Ctrl-U
这是 VS 2008,不确定 Express 版本是否有相同的东西。
the key combination
Comment Ctrl-K , Ctrl-C
Uncomment Ctrl-K , Ctrl-U
That's VS 2008, not sure if the express editions have the same thing.
Mauro 对快捷方式的看法是正确的,它们也在 Express 中。 您还可以在“编辑”->“高级”菜单中访问“注释/取消注释”块命令。 您可能还有一个工具栏图标来执行此操作,该图标看起来像几行,其中有一些缩进的蓝色行。
Mauro is right about the shortcuts, they're in Express as well. You can also get to the Comment/Uncomment block commands in the Edit->Advanced menu. You probably also have a toolbar icon to do this that looks like a couple of lines, with a few indented blue ones.
Visual Assist X 对此也有更好的快捷方式:
,但我不确定 Visual Assist 是否适用于 Express 版本
Visual Assist X also has better shortcuts for this:
I'm not sure if it Visual Assist works with The express edition though