473,385 Members | 1,930 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

how to get the recipients addresses of an outlook mail in python...

Hi all,
Can some one help me in obtaining the set of recipients email
addresses from an outlook mail? I tried various options like

message.Recipient.Address
message.To.Address
message.Receiver.Address etc.. but I could get the senders address
using message.Sender.Address.
Thanks in advance,
Venu.
Oct 16 '08 #1
4 4227
* * * * Can some one help me in obtaining the set of recipients email
addresses from an outlook mail? I tried various options like ...
message["To"]
message["Cc"]

HTH,
--
Miki
http://pythonwise.blogspot.com
Oct 16 '08 #2
On Oct 16, 5:22*pm, Miki <miki.teb...@gmail.comwrote:
* * * * Can some one help me in obtaining the set of recipientsemail
addresses from an outlook mail? I tried various options like ...

message["To"]
message["Cc"]

HTH,
--
Mikihttp://pythonwise.blogspot.com
Thanks for your reply... Sorry , it didn't work...
session = Dispatch("MAPI.session")
session.Logon('outlook') # MAPI profile name
inbox = session.Inbox
message = inbox.Messages.Item(i + 1)
rec = message["To"]
print rec

I did some thing like the above code...it said the below error...
raise TypeError, "This object does not support enumeration"
TypeError: This object does not support enumeration
Thank you,
Venu.
Oct 16 '08 #3
ve***********@gmail.com wrote:
On Oct 16, 5:22 pm, Miki <miki.teb...@gmail.comwrote:
>> Can some one help me in obtaining the set of recipients email
addresses from an outlook mail? I tried various options like ...
message["To"]
message["Cc"]

HTH,
--
Mikihttp://pythonwise.blogspot.com

Thanks for your reply... Sorry , it didn't work...
session = Dispatch("MAPI.session")
session.Logon('outlook') # MAPI profile name
inbox = session.Inbox
message = inbox.Messages.Item(i + 1)
rec = message["To"]
print rec

I did some thing like the above code...it said the below error...
raise TypeError, "This object does not support enumeration"
TypeError: This object does not support enumeration
This report is impossibly vague. If you really need help then please
take the trouble to provide *exactly* the code you used (pasting from
the actual program) and the full traceback. Otherwise we don't even know
which statement is going wrong, let alone how.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC http://www.holdenweb.com/

Oct 17 '08 #4
ve***********@gmail.com wrote:
On Oct 16, 5:22 pm, Miki <miki.teb...@gmail.comwrote:
>> Can some one help me in obtaining the set of recipients email
addresses from an outlook mail? I tried various options like ...
message["To"]
message["Cc"]

HTH,
--
Mikihttp://pythonwise.blogspot.com

Thanks for your reply... Sorry , it didn't work...
session = Dispatch("MAPI.session")
session.Logon('outlook') # MAPI profile name
inbox = session.Inbox
message = inbox.Messages.Item(i + 1)
rec = message["To"]
print rec

I did some thing like the above code...it said the below error...
raise TypeError, "This object does not support enumeration"
TypeError: This object does not support enumeration
This report is impossibly vague. If you really need help then please
take the trouble to provide *exactly* the code you used (pasting from
the actual program) and the full traceback. Otherwise we don't even know
which statement is going wrong, let alone how.

regards
Steve
--
Steve Holden +1 571 484 6266 +1 800 494 3119
Holden Web LLC http://www.holdenweb.com/

Oct 17 '08 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Alex Hunsley | last post by:
I'm using the smtp module to send emails from python. I would like to specify several recipients of the email like follows: msg = MIMEText(time.ctime("Body text of email") me =...
8
by: dccarson | last post by:
Here is a snippet of code which does not send to all recipients. However, it also does not inform me of this error. My suspicion is that this only fails for users with longer usernames. The two I...
15
by: news.microsoft.com | last post by:
HI, ASPEmail to send to multiple recipients? I tried to use comma and semicolon but all the time give this message error: Error: 6 - 501 Bad address syntax nor :...
4
by: dmiller23462 | last post by:
So here's my problem.....I need to set up different email distributions based on which option in the following Select form has been chosen....For instance if "Putaway" is chosen it needs to email...
2
by: .Net Newbie | last post by:
Hello, I am currently coding my ASP.Net pages in c# and have run into a question concerning Emails. I have four objects on a page (six including 2 buttons). The first is a subject line...
4
by: Michelle | last post by:
Hi Is it possible/anyone know how to send a document (.pdf) to multiple recipients using POP where the email is not just a matter of throwing 1000 email addresses in the BCC list, but each email...
2
by: mik.sjoblom | last post by:
Hello, I have developed a Access application that needs to read mail from Outlook, versions on Access and outlook are 2003. In the code i use mapi to connect to outlook. When i tries to read the...
1
by: sxwend | last post by:
I am trying to use the following post results (http://www.thescripts.com/forum/thread189759.html) and add another requirement. I need to send the results to just the email addresses that the query...
1
by: Sergeles | last post by:
I am currently in the process of making/maintaining a database for a school club. I started the database mostly from scratch and i have a pretty good familiarity with Access (been using it for almost...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.