How can get the currently selected text in Microsoft Outlook 2007
- in an open message window
- or in the currently selected message in the preview pane
and copy it into the clipboard?
I am using Microsoft Outlook 2007.
What I already tried
I know that I can use DataObjects to put text into the clipboard or get text from the clipboard.
The difficulty is to get the currently selected text
I tried the following commands:
- Outlook.activeexplorer.selection.item(1). ...
in many variations, but with no success.
I found some sources stating that it would not be possible to get the currently selected text in Outlook via VBA but I think it must at least be possible to invoke a Ctrl-C (copy) command and then use the content of the clipboard.
I also stumbled upon some solutions with the Inspector as described here, but I got an error message. Maybe it is because I forgot to reference the "MS Word Object Library" - I'll try that on Monday.