Problem with Item.SenderName

A

Amit Basu

Hi,

I send an Outlook form as a MailItem outside of our domain. The
recipient needs to forward that mail, after making some modifications to
the form, to a set of people WHO ARE NOT in his Contacts. I need to fill
the addressee list programmatically. Here is what I used:

Function Item_Forward(ByVal ForwardItem)
ForwardItem.To = Item.Sendername
ForwardItem.Cc = "(e-mail address removed)"
End Function

The To addressee is getting populated with the DISPLAY NAME of the
Sender like "John Doe" and not the email ID. As a result it is not being
resolved and generating an error while Sending the form. How do I
retrieve the email ID of the sender and not the display name?

I am using Outlook 2000 and Exchange 5.5?

TIA,
Amit.
 
S

Sue Mosher [MVP]

A

Amit Basu

Sue, Thanks a lot.


There is no Outlook property that returns the sender's email address.
You can either use CDO (or Redemption to avoid security prompts --
http://www.dimastr.com/redemption/) to get the From address or use
Outlook to get the Reply To address. Sample code at
http://www.slipstick.com/dev/code/getsenderaddy.htm.

--
Sue Mosher, Outlook MVP
Outlook and Exchange solutions at http://www.slipstick.com
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

Top