Multiple Line Editing in Visual Studio 2010

By | March 28, 2011

In one of my old tips I have discussed about how we can select a code block in Visual Studio by selecting “ALT” key. In this tips I will be discussion how that code block selection helps us to edit multiple line editing in VS 2010. Let’s say you have below code block,


Now, suddenly you found DateTime  list name does not matching with your coding standards, so you want to rename it to “datetimes”. Below is the two easy tricks for the same.

First change the list name to “datetimes” and press “Ctrl + . “ and Press Enter, this will automatic rename all the “listdatetimes” to “datetimes”


More details can be found

Now, if you are in VS 2010, you can edit multiple line of code at same time. first change the “listdatetimes” to “datetimes” and then select all the old lastdatetimes variables using “ALT” key as shown in below and start typing the new variable name.


Here is a nice video which talked about multiple line editing

Multiple Line Editing and Box Selection

One thought on “Multiple Line Editing in Visual Studio 2010

  1. Pingback: Dew Drop – March 28, 2011 | Alvin Ashcraft's Morning Dew

Comments are closed.