A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Address book, strange behavior



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old May 20th 06, 09:44 PM posted to microsoft.public.outlook.program_vba
[email protected]
external usenet poster
 
Posts: 1
Default Address book, strange behavior

I created a VB module in Access which placed items in a Contact folder
in Outlook. It seems to work fine, as all the entries show up as
expected when viewed in Outlook for when viewing a linked table in
Access. However, if I open the "Address Book" and point it to the
folder the items do not show up. An idividual item only shows in the
Address Book if I edit it within Outlook, not if it is placed there by
Access.

Does anyone know why this is happening and how to fix it?

Shane

shanej2015 at yahoo dot com

Ads
  #2  
Old May 23rd 06, 08:23 PM posted to microsoft.public.outlook.program_vba
Sue Mosher [MVP-Outlook]
external usenet poster
 
Posts: 11,651
Default Address book, strange behavior

Probably because creating it in Access doesn't "resolve" the email address. Show a code snippet to illustrate how you're creating the item.

--
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

wrote in message oups.com...
I created a VB module in Access which placed items in a Contact folder
in Outlook. It seems to work fine, as all the entries show up as
expected when viewed in Outlook for when viewing a linked table in
Access. However, if I open the "Address Book" and point it to the
folder the items do not show up. An idividual item only shows in the
Address Book if I edit it within Outlook, not if it is placed there by
Access.

Does anyone know why this is happening and how to fix it?

Shane

shanej2015 at yahoo dot com

  #3  
Old May 25th 06, 03:47 AM posted to microsoft.public.outlook.program_vba
shanej2015 at yahoo dot com
external usenet poster
 
Posts: 3
Default Address book, strange behavior

Sub FAXList(e1, e2, e3, e4)

Dim loOutlook As Outlook.Application
Dim loNS As Outlook.NameSpace
Dim loContactitem As Outlook.ContactItem
Dim loSafeItem As Object
Dim objFolder As Outlook.MAPIFolder
Dim MyNewFolder As Outlook.MAPIFolder

Set loOutlook = CreateObject("Outlook.Application")
Set loNS = loOutlook.GetNamespace("MAPI")
loNS.Logon
Set objFolder =
loNS.GetDefaultFolder(olFolderContacts).Folders("m edia")
Set loContactitem = objFolder.Items.Add
'Set loContactitem = loOutlook.CreateItem(olContactItem) ''
This creates the ContactItem Object
Set loSafeItem = CreateObject("Redemption.SafeContactItem")

With loSafeItem
.Item = loContactitem ' This attaches the Object to
' Redemption SafeContactItem Object
.BusinessFaxNumber = e3
.FirstName = e1
.LastName = e2
.CompanyName = e4
.Recipients.ResolveAll
.Save
End With

Set loOutlook = Nothing
Set loNS = Nothing
Set loContactitem = Nothing
Set loSafeItem = Nothing

End Sub

  #4  
Old May 26th 06, 09:10 PM posted to microsoft.public.outlook.program_vba
shanej2015 at yahoo dot com
external usenet poster
 
Posts: 3
Default Address book, strange behavior

any ideas?

  #5  
Old May 26th 06, 10:56 PM posted to microsoft.public.outlook.program_vba
shanej2015 at yahoo dot com
external usenet poster
 
Posts: 3
Default Address book, strange behavior

Well I got it to work, FINALLY. All I did was switch the order of the
fields from above to

.FirstName = e1
.LastName = e2
.BusinessFaxNumber = e3
.CompanyName = e4
.Recipients.ResolveAll
.Save

in other words don't add the email, or phone/fax numbers first. do the
names first.

Shane

 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Strange Post SP2 Behavior [email protected] Outlook - Using Contacts 4 March 29th 06 11:10 PM
Strange behavior after workstation re-install Robert Perez Outlook - General Queries 1 March 8th 06 07:11 PM
Strange calendar behavior Dan Outlook - Calandaring 1 February 25th 06 04:12 AM
Wierd Fax Address Book Behavior PowerUser Outlook - Fax Functions 1 January 31st 06 10:20 AM
strange encryption behavior Larry Outlook - General Queries 0 January 24th 06 09:26 PM


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


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.