Obtain SMTP Address using CDO in an un-managed environment

You can use the AddressEntry.Fields(PR_SMTP_ADDRESS) method where PR_SMTP_ADDRESS is 0x39FE001E.   Here are two examples of it:   ‘ MAPI property tag for SMTP address           ‘ Get first message from inbox         Set objFolder = objSession.Inbox         Set objMessages = objFolder.Messages         Set objMessage = objMessages.GetFirst()                 ‘ Get address         Set…

0

Obtain SMTP Address using CDO/Outlook in managed environments

If you were targeting office 2003 clients, you can download the Office 2003 primary interop libraries here: http://www.microsoft.com/downloads/details.aspx?familyid=3c9a983a-ac14-4125-8ba0-d36d67e0f4ad&displaylang=en   This will allow your application to communicate with the Outlook object model (OOM) using interop. Once you have installed and connected with this, then you can query the OOM.   For example: Outlook.Application myApp = new…

0