Automatically Setting the Subject & Recepient fields

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Can anyone advise how to access (via VBA code) the outlook Subject &
Recepient from VBA in MS Word?

When I click the Email button in word and the Subject & Recepient fields
appear, I want to be able to fill these fields out automatically.

i.e. Subject = "blah blah"
To = "Joe Blogs"

I have seen how to do this from VBA programmed in outlook, but am not sure
how to refrence these fields when they are part of other documents... i.e. in
Word

Can anyone advise?
 
Office 2003...

Sue Mosher said:
What version of Office?
--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
The mail "envelope" is exposed as Activedocument.MailEnvelope. To set the
subject, you can use

ActiveDocument.MailEnvelope.Item.to = "My Subject"

Etc.

--
Sue Mosher, Outlook MVP
Author of
Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top