Iterate the Recipients collection and check each Recipient.AddressEntry.Type. If it's "EX," it's an Exchange recipient.
-- Sue Mosher, Outlook MVP Author of Configuring Microsoft Outlook 2003 http://www.turtleflock.com/olconfig/index.htm and Microsoft Outlook Programming - Jumpstart for Administrators, Power Users, and Developers http://www.outlookcode.com/jumpstart.aspx <david.ing[ at ]gmail.com> wrote in message news:1142704106.122400.226070[ at ]g10g2000cwb.googlegroups.com...
[Quoted Text] > Hi, > > I have an open Inspector window and a new mail being written. Once the > Send is hit I can subscribe to the App.ItemSend event and examine the > message. > > What I need to be able to do is tell if any of the recipients on the > To/CC/ fields are Exchange users or not. > > Example: > > User Bob has an exchange account, and is using Outlook. He sends a > single email to Alice and Frank. Alice is on the same exchange server > as Bob, while Franks in on something else, say gmail. > > I want to be able to distinguish that this message in Outlook has at > least one non-Exchange user as the destination. > > Is this possible? I'm guessing some sort of CDO call for the > Recipients, plus maybe the Address Type from EMAPI property, but you > guys are smarter than me and may already know the best way. :-) > > Thanks! >
|