This project has moved. For the latest updates, please go here.

Use the Outlook.MailItem.Sender Object

Jun 22, 2011 at 3:09 PM

Hi!

I need to understand how I can control the Outlook.MailItem.Sender Object.

mailItem.SenderName = UserStuff.LoggedInUser.FirstName  + " " + UserStuff.LoggedInUser.LastName;
mailItem.SenderEmailAddress = UserStuff.LoggedInUser.Email;

The above code will not compile as these properties are read only. How shall I go about if I need to change the Sender Name and Email?

Regards.

Coordinator
Jun 22, 2011 at 3:11 PM

please try mailItem.SentOnBehalfOfName