Python Outlook How to send reply email with different email account

Joined
Mar 26, 2014
Messages
1
Reaction score
0
Hi,
I want to send back reply to the same email but with different email account.
Here is my script

mail = outlook.Session.GetItemFromID(ID)
subject = mail.Subject
c = mail.Sender.Address
if mail:
message_reply = mail.Reply()
message_reply.From='_from_email' # not working #
message_reply.Body = "THE FOLLOWING TASK HAS BEEN MARKED AS COMPLETED: \n\n"
message_reply.CC= '_CC_Email'
message_reply.Send()

I tried message_reply.From, message_reply.Sender.Address, mail.From but nothing is working. It is sending from my default email account.
message_reply.CC, message_reply.Body is working.

Can anyone help me out?
 

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

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,014
Latest member
BiancaFix3

Latest Threads

Top