It is a visual studio macro that originally came from JP Boodhoo's Nothing But .NET Boot Camp class. This is it:
Sub ConvertLine()
If DTE.ActiveDocument Is Nothing Then Return
Dim isOpen As Boolean = OpenUndo("ConvertLine")
Dim selection As TextSelection = CType(DTE.ActiveDocument.Selection(), EnvDTE.TextSelection)
selection.SelectLine()
If selection.Text = "" Then Return
Dim classKeyword As String = "class """
Dim methodKeyword As String = "void """
Dim classIndex As Integer = selection.Text.IndexOf(classKeyword)
Dim methodIndex As Integer = selection.Text.IndexOf(methodKeyword)
If classIndex + methodIndex < 0 Then Return
Dim index = CType(IIf(classIndex >= 0, classIndex, methodIndex), Integer)
Dim prefix = selection.Text.Substring(0, index) + CType(IIf(classIndex >= 0, classKeyword, methodKeyword), String)
Dim description As String = selection.Text.Replace(prefix, String.Empty)
Dim conversion As String = Common.ReplaceSpacesWithUnderscores(description)
conversion = Common.ReplaceApostrophesWithUnderscores(conversion)
conversion = Common.ReplaceQuotesWithUnderscores(conversion)
selection.Text = prefix.Replace("""", String.Empty) + conversion
If prefix.Contains(methodKeyword) Then selection.LineDown() Else selection.LineUp()
selection.EndOfLine()
CloseUndo(isOpen)
End Sub