HighTechTalks DotNet Forums  

VSTO - Determine the received emailaddress from an Mailitem

Visual Studio.net (Tools Office) microsoft.public.vsnet.vstools.office


Discuss VSTO - Determine the received emailaddress from an Mailitem in the Visual Studio.net (Tools Office) forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Alex
 
Posts: n/a

Default VSTO - Determine the received emailaddress from an Mailitem - 04-07-2010 , 06:43 AM






Hello!

I have the problem, that I cant find (google, bing) the correct property to
get the E-Mail Address that received the Mailitem. If I get a Mail with
sales (AT) company (DOT) com and support (AT) company (DOT) com (the sender sent the mail to both
addresses) I want to know which Item comes from Sales and which from
Support.

Thanks for Help

Alex

Reply With Quote
  #2  
Old   
Ken Slovak - [MVP - Outlook]
 
Posts: n/a

Default Re: VSTO - Determine the received emailaddress from an Mailitem - 04-07-2010 , 08:16 AM






There is a ReceivedByName property for a mail item that you can use. If
that's not what you want and you want an email address you need to use
either the Outlook 2007 PropertyAccessor or a different API such as
Redemption (www.dimastr.com/redemption).

In Outlook 2007 once you get a PropertyAccessor object on a MailItem you can
use the following DASL property tag with the PropertyAccessor.GetProperty()
method to retrieve the receiving email address:
"http://schemas.microsoft.com/mapi/proptag/0x0076001E". This is a string
DASL property tag, not a Web URL, that represents the MAPI
PR_RECEIVED_BY_EMAIL_ADDRESS property.

That property will be in the form of an Exchange DN if the receiving address
represents a member of an Exchange GAL.

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Professional Programming Outlook 2007.
Reminder Manager, Extended Reminders, Attachment Options.
http://www.slovaktech.com/products.htm


"Alex" <pbnewsgroup (AT) hyperbird (DOT) de> wrote

Quote:
Hello!

I have the problem, that I cant find (google, bing) the correct property
to get the E-Mail Address that received the Mailitem. If I get a Mail with
sales (AT) company (DOT) com and support (AT) company (DOT) com (the sender sent the mail to
both addresses) I want to know which Item comes from Sales and which from
Support.

Thanks for Help

Alex

Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.