how to set the sender for a message

how to set the sender for a message

Post by xingchen » Thu, 23 May 2002 09:33:50

I am using CDO here. The steps I took are:
log onto my mailbox
create a message in outbox
set the subject, txt, etc.
Send message.

Everything is fine except that in configuring the message, I want to set the
sender to be something other than myself. How can I do that? You can't
create an AddressEntry object out of blue. I tried to do
AddressEntryPtr pSender = pMessage->Sender

but I got a COM error saying MAPI_E_NOT_FOUND, suspect this has to do with
the fact that Sender property does not correspond to any MAPI property.

How can I set the sender for the message that's going out?



how to set the sender for a message

Post by Jason Johnston [M » Thu, 23 May 2002 22:40:38

You can only use CDO to send mail on behalf of another user that you have
permission to send on behalf of.

Q239568 HOWTO: How to  Send Message On Behalf Of Another User;EN-US;Q239568

Hope that helps!

Jason Johnston
Microsoft Developer Support - Messaging

This posting is provided "AS IS" with no warranties, and confers no rights.


1. Setting the sender property of the message in CDO

How can I change the sender property of a message? This code doesn't seem to work.

Set objNewMessage = objMessage.CopyTo(objSession.getDefaultFolder(2).ID)
objNewMessage.Sent = False
Set objNewMessage.Sender = objSession.CurrentUser

2. C++ compiler for 8051

3. Setting sender name in an email message

4. IPTUNNEL & vlms...


6. Remoting Events

7. Setting the sender details with Mapi

8. DECC: what is %CC-E-STOREQEXC,

9. setting Sender Address

10. How to set sender return address?

11. USENET message-id generated by sender?

12. Custom message sender address ?

13. Getting Sender of a Message