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)
The keyboard shortcut is Ctrl+K, Ctrl+S.
Technorati tags: VS2005Tip, VS2008Tip
Comments
Anonymous
December 16, 2007
PingBack from http://geeklectures.info/2007/12/17/did-you-know-how-to-insert-a-code-snippet-around-a-block-of-code/Anonymous
December 17, 2007
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!Anonymous
February 03, 2008
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 allAnonymous
March 29, 2009
C# и XML поддерживают команду Edit.SurroundWith, которая предназначена для вставки шаблонов вокруг выделенного