VS.Net Tip/Trick
Thanks to Roy for this macro to insert Region statements in your code. I updated it a bit for VB.Net peeps.
Sub OutlineSelection()
Dim objTextDoc As TextDocument
Dim title As String = InputBox("Enter the title for the outline", "Outline code")
objTextDoc = DTE.ActiveDocument.Object("TextDocument")
objTextDoc.Selection.Insert("#Region """ & title & "" & vbNewLine, vsInsertFlags.vsInsertFlagsInsertAtStart)
objTextDoc.Selection.Insert(vbNewLine & "#End Region ", vsInsertFlags.vsInsertFlagsInsertAtEnd)
objTextDoc.Selection.SmartFormat()
End Sub
--
Composed with Newz Crawler 1.4 http://www.newzcrawler.com/