I am very new to writing VSIX Extensions, and am currently working on figuring out how to examine & edit the text in the editor. At the moment, I have managed to figure out how to get the following:
Dim CurrentLine As String = view.Caret.Position.BufferPosition.GetContainingLine().GetText() Dim CurrentChar As Char = view.Caret.Position.BufferPosition.GetChar() Dim CurrentIndex As Integer = view.Caret.Position.BufferPosition.Position Dim CurrentLineIndex As Integer = view.Caret.Position.BufferPosition.GetContainingLine().LineNumber
Some of the things I am trying to figure out how to do/get are:
1. Other lines based on the CurrentLineIndex
2. Column & Character position of view.Caret (the values displayed in the Status Bar as Col & Ch)
3. Move view.Caret to a new position
Any help would be appreciated. Thanks.
Nathan Sokalski njsokalski@hotmail.com http://www.nathansokalski.com/