How to fetch the text highlighted when a Context Menu is selected

Add-in Express™ Support Service
That's what is more important than anything else

How to fetch the text highlighted when a Context Menu is selected
 
Bob Milani




Posts: 13
Joined: 2005-01-28
Hi,

I am trying to find out what text is highlighted when they righ-click on a context menu created using add-in. I am using the "Text" commandbar in word and I am adding a submenu and I like to fetch the text that is highlighted. How do I fetch this text?

Thank you,
Bob
Posted 19 Mar, 2006 19:41:41 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi Bob.

You need to use the Word.Selection interface of the active window to get the text that is selected in a document. Please look at our ADX Toys for Word example. It should help you.
http://www.add-in-express.com/downloads/free-addins.php
Posted 20 Mar, 2006 17:01:57 Top