View Single Post
  #1  
Old September 4th 08, 02:54 PM posted to microsoft.public.outlook.program_addins
Steffen Grellmann[_2_]
external usenet poster
 
Posts: 9
Default Retrieve actual value of .To without saving first?

Hi newsgroup,

as you can see from the code snippet below I'm trying to read the
content from the "To" field of a new Outlook mailmessage. It seems
that the item has to been saved first in order to get the \actual\
value from the .To-field.

I guess some of you will recommend to work with the Recipients
collection instead. If doing so, saving the item seems to be required
too to get actual values.

Is there another way that does not require to save the item first?

Dim itm As Object
Set itm = ActiveDocument.MailEnvelope.Item

With itm
MsgBox .To
End With

Set itm = Nothing

Kind regards,

Steffen
Ads