Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default populating list box with contacts

I am trying to populate a list box in excel with the FirstName object of my
outlook2000 contacts; then when the user selects a FirstName, I retrieve
items like email address for the contact they selected and store to a cell in
the sheet.

I feel like Edison working on the light bulb. Any help would be greatly
appriciated.

Thanks,
George
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default populating list box with contacts



"GeorgeFD29" wrote:

I am trying to populate a list box in excel with the FirstName object of my
outlook2000 contacts; then when the user selects a FirstName, I retrieve
items like email address for the contact they selected and store to a cell in
the sheet.

I feel like Edison working on the light bulb. Any help would be greatly
appriciated.

Thanks,
George


I have the following code working - talking to outlook. However, whenever I
try to return the email address of the contact, I get 'object doesn't support
this property or method' thanks for any help.

Dim OLF As Outlook.MAPIFolder
Dim olContactItem As Outlook.ContactItem
Dim ToContact As Recipient
Set OLF = GetObject("",
"Outlook.Application").GetNamespace("MAPI").GetDef aultFolder(olFolderContacts)

Set itms = OLF.Items

If itms.Count = 0 Then
MsgBox "No contacts to add to drop-down list"
Exit Sub
End If


For i = 1 To itms.Count
Set itm = itms(i)
strContactName = itm.LastName & ", " & itm.FirstName & " " & itm.MiddleName
strEmail = itm.email
Next
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I export contacts from Excel back to Outlook Contacts? corvettego Excel Discussion (Misc queries) 2 August 17th 09 06:29 PM
Exporting Contacts list to Excel RichDT Excel Discussion (Misc queries) 2 August 13th 08 02:20 AM
.AddItem list and populating combobox with created list pallaver Excel Discussion (Misc queries) 8 June 27th 08 12:36 PM
Moving contacts from one list to another Munchichic Excel Discussion (Misc queries) 2 March 26th 06 11:58 PM
Populating dropdown list 2 with data depending upon what was selected in list 1 karambos Excel Programming 2 November 9th 04 05:32 PM


All times are GMT +1. The time now is 03:47 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"