Welcome to MSDN Blogs Sign in | Join | Help

Sara Ford's Weblog

My adventures embracing open source on CodePlex and at Microsoft

News

    • Did you know... All author proceeds go directly to sending Hurricane Katrina survivors to college.

      Microsoft Visual Studio Tips book

      Recent Entries

Did you know... how to insert a code snippet around a block of code? - #108

C# and XML support the Edit.SurroundWith command that will insert the desired snippet around the selected code (whether it is just a selected word, selected line, or entire function)

Code Snippet Surround With

for loop surrounding a for loop

The keyboard shortcut is Ctrl+K, Ctrl+S.

Technorati tags: ,
Posted: Monday, December 17, 2007 3:00 AM by saraford

Comments

Jimbo said:

It seems that the Edit.SurroundWith command appears in VS2005 when working in VB, however when I try to use it, I get an error saying it is "not currently available".  I'm assuming this is because I'm using VB instead of C#?  Will VS2008 support these cool features too? :)  Love your column!

# December 17, 2007 1:08 PM

dwayne said:

I don't no want you are taking about but that is way am here to leran if you can help me do I want to no all i can this the job for me think you for all

# February 3, 2008 12:57 PM

Секреты Visual Studio said:

C# и XML поддерживают команду Edit.SurroundWith, которая предназначена для вставки шаблонов вокруг выделенного

# March 30, 2009 1:04 AM
New Comments to this post are disabled
Page view tracker