View Single Post
  #2   Report Post  
galimi
 
Posts: n/a
Default

You can link to data in Outlook from Excel using VBA and navigating through
the Outlook Object Model.

I have posted an example file to http://www.Galimi.com/Examples/Outlook.xls

Following is the code that should be enough to complete what you wish to
accomplish:

http://HelpExcel.com

Sub getOutlook()
Set myOLAPP = CreateObject("Outlook.Application")
'Dim myOLAPP As New Outlook.Application


Set mynamespace = myOLAPP.GetNamespace("MAPI")
Set myAddressList = mynamespace.Folders(1).Folders(6).Items

For Each strItem In myAddressList
shtImport.Range("a2").Offset(r) = strItem.FirstName
shtImport.Range("b2").Offset(r) = strItem.LastName
r = r + 1

Next


Set oOL = Nothing
End Sub


"Bokeltri" wrote:

I have contact information in my excel spreadsheet that I update manually. I
would like to link these fields to my Outlook cantact data instead. Can this
be done and how?