Error During Contact Synchronization

Description

The error is related to contacts in the Global Address List in Microsoft Exchange.

The log contains this error:

--- [HASH: 86FC5CD449ADA81BBF39349CFC8DA6B0] ---
Could not finish first contact synchronization
System.InvalidOperationException: Unable to import item 'John Doe' from folder 'Contacts' ---> System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.Runtime.InteropServices.COMException: Error in IAddrBook.OpenEntry: MAPI_E_UNKNOWN_ENTRYID
ulVersion: 0
Error: The item could not be found.
ulLowLevelError: 0
ulContext: 0
   at Redemption.IRDOSession.GetAddressEntryFromID(String EntryID, Object Flags)
   at eWay.Core.OutlookAccess.Application.GetSmtpAddress(String entryId)
   at eWay.Core.OutlookAccess.ContactItem.get_Email1Address()
   --- End of inner exception stack trace ---
   at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
   at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Reflection.RuntimePropertyInfo.GetValue(Object obj, BindingFlags invokeAttr, Binder binder, Object[] index, CultureInfo culture)
   at System.Reflection.RuntimePropertyInfo.GetValue(Object obj, Object[] index)
   at eWay.Core.ReflectionHelper.GetPropertyValue[T](Object obj, Type type, String propertyName, BindingFlags flags, T& value)
   at eWay.Core.OutlookAccess.ItemBase.GetFieldValue(String outlookFieldName)
   at eWay.Core.OutlookAccess.ItemBase.get_Item(String outlookFieldName)
   at eWay.Core.OutlookAccess.Library.CopyItemInfo(ILocalItemStore itemStore, OutlookItem diItem, ItemBase olItem)
   at eWay.Core.OutlookAccess.Library.CreateItem(ILocalItemStore itemStore, ItemBase olItem, Guid itemGuid, String folder)
   at eWay.Core.OutlookStub.ImportItemBase..ctor(ILocalItemStore itemStore, ItemBase itemBase, OutlookItemDescriptor itemDescriptor)
   at eWay.Core.OutlookStub.ContactImportItem..ctor(ILocalItemStore itemStore, ItemBase itemBase, OutlookItemDescriptor itemDescriptor)
   at eWay.Core.OutlookStub.ImportItemsFactory.GetItem(ILocalItemStore itemStore, OutlookItemDescriptor itemDescriptor, ItemBase baseItem)
   at eWay.Core.OutlookStub.OutlookImportManager.SynchronizeSynchronously(ILocalItemStore itemStore, OutlookItemDescriptor itemDescriptor, ItemBase item)
   --- End of inner exception stack trace ---
   at eWay.Core.OutlookStub.OutlookImportManager.SynchronizeSynchronously(ILocalItemStore itemStore, OutlookItemDescriptor itemDescriptor, ItemBase item)
   at eWay.Core.OutlookStub.InitialContactSynchronizator.ImportOutlookContacts(IOutlookApplication outlookApplication, Int32 contactsCount, Int32& currentIndex, List`1& importedOutlookContacts)
   at eWay.Core.OutlookStub.InitialContactSynchronizator.DoFirstContactSynchronization(Int32 contactsCount, IOutlookApplication outlookApplication, IOutlookItemStore itemStore)
--- END TRACE ---

There might be identifier (GUID) of the contact in the log:

Unable to save item 'dc08bf92-7838-422c-939d-f0aec0c58434' from folder 'Contacts' to Outlook

Version

All versions of eWay-CRM

Difficulty

High

Resolution

Follow these steps to fix the error:

  1. Look for a contact in Microsoft Outlook that was named in the error. In the case you know the GUID of the contact, please see this article: How to Search Using Unique Identifier (GUID) in eWay-CRM,
  2. Delete its email address and write it again manually.
  3. Save the contact.
  4. Synchronization should now proceed correctly, but you may need to repeat the procedure for other contacts.