Reading emails & email headers from Outlook mail using C# – Part II
Hi Guys! This is continuation of my previous entry on reading emails and email header from Outlook PST file using C#. If you somehow, missed the first part you can have a look at it here
So in my previous part, I showed you how you can read header of an email from a PST file by specifying a particular header name (e.g. CC List, TO list, Subject, From etc), however, our requirement was to make the email message RFC 822 compliant but when you try to read header of an email item you wont be able to find all header in email item object, so here’s is the only way that you can read all headers in just one GO…
string SchemaTransportHeader = @"http://schemas.microsoft.com/mapi/proptag/0x007D001E";
Console.WriteLine(item.PropertyAccessor.GetProperty(SchemaTransportHeader));
Console.WriteLine(item.PropertyAccessor.GetProperty(SchemaTransportHeader));
These two lines will provide you all headers of a particular item. Hopefully this will help you all in reading emails from Outlook (PST) file and making them RFC 822 compliant.
Happy coding dudes! Thanks
- Posted in: Uncategorized
Well Done dear … Keep it ON … Keep it UP …
Ahmed, thanks for the post ..However I do have a kinda separate question. Do you have any idea how to change the color of the calendar from C#???I’m writing C# code to access a non-primary calendar in Outlook 2007 and I wanted to allow the user to change the color of the calendar. Any help is highly appreciated. Thanks :)
i’m student and
i have project to read outlook 2007 using c# 2010
can you help me?
thanks