
February 21st 06, 03:48 PM
posted to microsoft.public.outlook.program_vba
|
|
How do I paste Clipboard contents using macro?
Thank you very much! I think I can take it from here.
--
Maureen
"Michael Bauer" wrote:
Am Mon, 20 Feb 2006 15:14:26 -0800 schrieb Maureen:
Maureen, you told us to have a script that runs fine in Word (but we don´t
see or know that code).
In Word you have a Document object which you´re using for sure. The same
object you can use in Outlook if Word is the mail editor. Sample:
Dim wd as Word.Document
Set wd=Application.ActiveInspector.WordEditor
Via the wd variable in Outlook you have now the same access to all the
Document´s properties like you would have in Word.
I think you can´t format the clipboard content itself. Instead you need to
insert it into the Word Document first, then set the proper Range object and
use the Range´s Font property.
Sample for formatting all the Document:
wd.Range.Font.Name = "courier new"
--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.vbOffice.net --
Well, I'm lost. I think Inspector must be part of VB and since I'm
learning
by seeing patterns in other code, I haven't run into that one yet. I
found
Tools/Reference in Outlook VB and checked the box for MS Word 10.0 Object
Library, but I'm not sure what to do next.
I'll keep reading and trying to make sense of it and will appreciate any
additional help you can give.
Thank you!
|