Hi all,
I am writing an add-in that manipulates selected text,
My question is- how do I get the selected text ?
I guess it should start with something like - "VBInstance.ActiveCodePane.CodeModule..."
Thanks !
Printable View
Hi all,
I am writing an add-in that manipulates selected text,
My question is- how do I get the selected text ?
I guess it should start with something like - "VBInstance.ActiveCodePane.CodeModule..."
Thanks !
.selText
Selected text of what?
I am writing a VB Addin, but I havent actually used selected text yet.
From what I have seen so far (this is just an educated guess), what you want is something like:
VBInstance.ActiveCodePane.CodeModule.GetSelection(a,b,c,d)
where a,b,c,d are numeric variables that will return the start/end positions of the selection (then use .Lines to get the relevant text)
Thanks all,
I finaly dicided to take the ugly way and use sendkeys to copy&paste and then taking the value from the clipboard...