import win32com.client as client
outlook=client.Dispatch("Outlook.Application")
#message=outlook.Createitem(0)
namespace=outlook.GetNameSpace('MAPI')
inbox=namespace.GetDefaultFolder(6)
message=inbox.items.add
message.To="allsourav@gmail.com;allsourav2@gmail.com"
message.CC="souravandamiya@gmail.com"
message.BCC="allsourav2@gmail.com"
message.Subject="Happy Birthday"
message.Body="Wish you a happy birthday ,learning outlook using python again"
message.Save()
message.Display()
message.Send()
Monday, September 13, 2021
Creating and sending a mail using default folder using outlook in python
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment