View Single Post
  #2  
Old July 10th 07, 09:52 PM posted to microsoft.public.outlook.program_addins
Dmitry Streblechenko
external usenet poster
 
Posts: 2,116
Default Recipient name as shown on the message

Do you really need whatever Outlook displays or the e-mail address? In the
latter case, use the MailItem.Recipients colection to read the
Recipient.Name and Recipient.Address properties.

Dmitry Streblechenko (MVP)
http://www.dimastr.com/
OutlookSpy - Outlook, CDO
and MAPI Developer Tool

"Istvan Becze" wrote in message
news
I'm developing an Outlook add-in and I trying to capture the recipient
name
in the same format as it is shown on the message as follows:

Assume you reply to an e-mail and you see the following resolved e-mail
address in the "To" field:
John Doe
I would like to capture the above entire string in my add-in. (Note: The
MailItem.To property will only return the display name, which is 'John
Doe'.)

Is there any other property of either the MailItem or the Inspector, that
will return the string that the user sees on the screen?

Do I have to recreate the string myself? The problem with this case is
that
Global address book addresses have different format (i.e. only the display
name is shown) on the screen.

Thanks,

Istvan



Ads