I developed a package for Visual Studio extension. As part of this, I have a context menu that should handle all the text content of the active document (HTML editor).
I understand how to get the current selection: TextSelection txtSelection = (TextSelection) _bllManager.CurrentDocument.Selection;
But I donβt understand how to get all the content of the code window in case nothing is selected.
I am currently using work-around by doing txtSelection.SelectAll (), but it moves the cursor and I don't want this.
Any suggestion?
Thanks.
source share