Jeffrey Palermo (.com)

Sponsors

The Lounge

News

Advertisement

Images in this post missing? We recently lost them in a site migration. We're working to restore these as you read this. Should you need an image in an emergency, please contact us at imagehelp@codebetter.com
New line shortcut keys for Visual Studio 2005 - level 200
I am a big fan of shortcut keys.  I find that if I can keep my hands on the keyboard and not reach for the mouse, my productivity stays high.  First, I want to say thanks to Steve Donie for this change in my mindset.  Steve has a key for everything, and if there is not a key for it, he has a batch script with a shortcut key mapped.  Below, I'll illustrate some shortcut keys I love.  Note, I use many, many shortcut keys that hook into Resharper, but these shortcut keys work in Visual Studio 2005.

ctrl+enter: Insert a line above the current line and jump to the new line
before:

after:

ctrl+shift+enter: Add a line below the current line and jump to the new line
before:

after:



Posted 02-02-2007 7:04 AM by Jeffrey Palermo
Filed under: ,

[Advertisement]

Comments

DotNetKicks.com wrote New line shortcut keys for Visual Studio 2005 - level 200
on 02-02-2007 8:15 AM

You've been kicked (a good thing) - Trackback from DotNetKicks.com

nyuser98 wrote re: New line shortcut keys for Visual Studio 2005 - level 200
on 02-02-2007 8:32 AM

Yes it is very nice. I am using this feature since last two years in Java Eclipse IDE.

The Original .NET Geek wrote New line shortcut keys for Visual Studio 2005 - level 200
on 02-02-2007 9:28 AM

When Jeff Palermo talks people should listen ;). He just posted an article on how to better stay off

asdkljfhas wrote re: New line shortcut keys for Visual Studio 2005 - level 200
on 02-02-2007 11:13 AM

Isn't shift+enter the same thing as just enter?

Jeffrey Palermo wrote re: New line shortcut keys for Visual Studio 2005 - level 200
on 02-02-2007 11:22 AM

asdkljfhas,

Yes it is.  Note to self:  Don't blog so early in the morning.

stevedonie wrote re: New line shortcut keys for Visual Studio 2005 - level 200
on 02-02-2007 1:43 PM

Thanks for the reference. I started using the keyboard very heavily in my first job, where I developed software for blind people. Blind people have terrible eye-hand coordination :-) This necessitates that they do EVERYTHING through the keyboard. In order to teach myself to be more like my customers, I would frequently drop my mouse down behind my desk so I couldn't reach it. When you start doing that, you start learning other ways of doing things.

Kamran wrote re: New line shortcut keys for Visual Studio 2005 - level 200
on 02-03-2007 4:36 AM

asdkljfhas, Palermo,

>Isn't shift+enter the same thing as just enter?

if you are refering to the post above, it says "ctrl+shift+enter" and not "shift+enter".

makka wrote re: Shortcut per Visual Studio 2005
on 02-03-2007 12:00 PM
makka wrote Shortcut per Visual Studio 2005
on 02-04-2007 4:33 AM
Jesper Hauge wrote re: New line shortcut keys for Visual Studio 2005 - level 200
on 02-04-2007 7:44 AM

Thanks ! Came in handy :)

On another note - how do you get VS 2005, to highlight the line with the cursor in it, I have been looking for this, but cannot find it in Options?

Regards

Jesper Hauge

Jeffrey Palermo wrote re: New line shortcut keys for Visual Studio 2005 - level 200
on 02-04-2007 2:22 PM

Jesper,

The line-highlighting is not a Visual Studio feature.  It's a Resharper feature.  You can read more about R# in one of my previous posts:

http://codebetter.com/blogs/jeffrey.palermo/archive/2006/08/02/BreadAndButterResharper.aspx