May 25, 2000 09:10 AM

Showing Contacts' Email Addresses

Rating: (0)
Windows IT Pro
InstantDoc ID #8845
In the June 2000 Outlook VBA on Demand column, I showed you how to use VBA in Outlook 2000 to display, for a message in your Inbox folder, the sender's email address. In this installment, I show you how to build a small application that loops through any folder containing contacts and updates the items so that an open contact's (or folder view's) email fields display the Internet email address—not the name of the contact.

Out...

ARTICLE TOOLS

You must be a paid Professional Member to access this entire article.

Already a Professional Member? Please log in now:

NOT A PROFESSIONAL MEMBER? YOU CHOOSE:

Monthly or Annual

Professional Membership

VIP Membership

Compare Member Benefits

Add a Comment

Worked like a charm.

Anonymous User 12/2/2004 2:20:28 PM


When I use the PR_EMAIL (&H39FE001E) field, all I get is "?????????????????"

Anonymous User 11/26/2004 10:50:25 AM


John & Shawn, to get the SMTP address from an Exchange sender or recipient, use CDO or Redemption and the PR_EMAIL (&H39FE001E) MAPI property to obtain the SMTP address from the AddressEntry object. See http://www.outlookcode.com/d/code/getsenderaddy.htm#redemption and http://www.cdolive.com/cdo5.htm#EMailAddressOfSender for examples.


SUE8/19/2004 6:40:33 PM


This code doesn't work for users in the same Microsoft Exchange Server 5.5/2000 organization, this technique shows the internal X.400 address instead of an easy-to-read SMTP address.

Shawn6/30/2004 7:59:31 PM


People in our company address book do not change. I use Outlook 2000 on a NT exchange server and get "/O=SPAN2000/OU=FIRST ADMINISTRATIVE GROUP/CN=RECIPIENTS/CN=JOHNA" for an address. I just want the company name part of the address. Thanks for any ideas.

John Alferes 12/5/2003 11:13:46 PM


Thanks for the code sample. It's a good idea - but it doesn't work. I tried to actually set the display to the value of the string variable, but of course, got the error msg that the property is read-only. Isn't there a way to set that property to read-only = false? I saw how to set a control on a form to not read-only, but can't see how to do it to a field they are using behind the scenes.

It's unbelieveable to me that a program as powerful as Outlook is so incredibly lame in certain areas. This is one example - why on earth would anyone want the person's full name displayed in the email address field?? This makes no sense and is of course, redundant since we already have botrh 'full_name' and 'file_as'.

Another doozy I haven't solved yet is: how come in Outlook Express - a far less powerful tool - can you simply start typing in email addresses in the 'TO' field and each new address automatically fills in the closest match - but in Outlook you can't do this? In Outlook it takes me a lot longer to enter email addresses when sending messages, because I have to click, then type, then click again (put the person in TO, CC or BC), then type again, then click again, etc. It's making me crazy. Anyway, if you know any way of getting autofill to function, please tell me - you'd be my new best friend :)

Rachel Tafoya 7/17/2003 1:26:00 PM


it doesn't work
I tried to step into the procedure
when it goes to .Email1Address = ""
the .Email1DisplayName and .Email1Address become empty
While when it goes to the next step
.Email1Address = strAddress
it assignes the .Email1DisplayName to be the original one again.

My system platform: winXp, Outlook 2000

Any comments?

brian6/19/2003 5:00:00 PM


What if the Email1AddressType is <> "SMTP"? In my case all my email address types are "EX" and I want to retrieve the SMTP version.

Jason12/7/2001 8:04:58 AM


You must use CDO. See http://www.cdolive.com/cdo5.htm#SMTPAddressOfCurrentUser for a code fragment you should be able to adapt.

Sue Mosher 3/26/2001 7:11:49 AM


Is there a way to programatically read the Global Address list to get the smtp address. This is using either VB or VBA with either CDO or the outlook application

Kenrick Robertson 2/24/2001 8:57:23 AM


You must log on before posting a comment.

Are you a new visitor? Register Here

windows server 2008 login scripts

I have 2 win2k8 servers one pdc and bdc. The domain is exampledom.com They are connected to 2 iscsi luns which replicate each other. We are running ac...222-96118

advertisement

GOOGLE LINKS
SPONSORED LINKS
FEATURED LINKS

White Papers

Your remote offices contain valuable electronic data – are they adequately protected? Learn how proven technologies can reliably and cost-effectively back up a branch office from a central location, in real time, to disk or tape, and even utilize existing backup solutions.

Downloads

PacketTrap IT is a comprehensive and affordable network management and application monitoring solution that solves problems associated with bandwidth, network and application performance, and connectivity. Gain insight into your network - try PacketTrapIT free for 21 days!

Web Seminars

IT administrators have to solve a myriad of problems. This web seminar outlines the ten most common systems management pains - including managing highly distributed systems and dealing with data theft/loss – and the best practices to address each.

eLearning Series

We bring the experts direct to you to share their real-world perspective and expertise. During each event, three sessions stream in real time, so you can learn, ask questions, and get solutions.
Upcoming event: Getting the Most with Exchange 2010 with Paul Robichaux

Subscribe to Windows IT Pro!

Windows is a trademark of the Microsoft group of companies. Windows IT Pro is used by Penton Media Inc. under license from owner.