Visual Studio Tips: Move or select code between matching braces

This short and quick post is inspired by the Blog Post (Read)  written by Pinal Dave (SQL Authority), describing shortcut to select code between two parenthesis in SQL Server. This can be very useful when we are working with complex queries. Fortunately, it is the same shortcut we use in Visual Studio (C++, C#).

To select code between two braces, we just need to press the key combinations CTRL+SHIFT+]  after placing the cursor either on the opening or closing brace (in C++ and C#: Curly brace/ Square bracket/ Parentheses).

Another thing we can do is – travel/move between two parenthesis using key combinations CTRL+] .(applies to both SQL Server and Visual Studio)

Thanks for reading.  

Advertisements

One thought on “Visual Studio Tips: Move or select code between matching braces

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s