[python-win32] Obtaining Outlook item properties from saved email file

Paul Moore p.f.moore at gmail.com
Mon Feb 16 15:30:55 CET 2009


Sorry, this is only peripherally a Python issue, as the code I'm
writing could just as easily be VBScript or any other language... But
as I'm writing in Python, and this group is full of helpful and
knowledgeable people... :-)

I have a folder full of emails saved from Outlook (.msg extension). I
want to extract from those files, the subject, sent/received date,
author, etc. Getting the properties isn't hard once I have a CDO
message object (or equivalent) to work with, but I've been unable to
find any way of getting a message object when all I'm given is the
filename of a ".msg" file in the filesystem.

Can anybody suggest a way to do this, or point me at sample code?

Once again, sorry for the mostly off-topic question, and thanks for any help.
Paul.


More information about the python-win32 mailing list