【发布时间】:2010-03-29 13:47:58
【问题描述】:
如何从宏中读取当前行(光标所在的位置)的文本?
我要使用这样的功能:
Public Sub AddTextToChangeLogFile()
Dim textOnACurrentLine As ???
textOnACurrentLine = ???
If textOnACurrentLine.Text <> String.Empty Then
Dim sw As New StreamWriter("C:\###\Changes.txt", True)
sw.WriteLine(textOnACurrentLine + ". file: " + DTE.ActiveDocument.Name)
sw.Close()
End If
End Sub
【问题讨论】:
标签: .net visual-studio winforms macros