Cannot update Location field in Contacts - Runtime Error 438

Not open for further replies.


Outlook version
Email Account
There seems to be a vast array of information regarding Outlook 2003 including information on how Microsoft love to change default field names. I'm guessing that may be my problem, or maybe it's an object problem - but I look to fellow Outlook 2003 users for assistance. Any help would be appreciated.

My code is as follows:

Dim olApp As Outlook.Application

Dim myNameSpace As Outlook.NameSpace

Dim objFolder As Outlook.MAPIFolder

Dim objItems As Outlook.Items

Dim objItem As Object, objAdd As Object

Dim new_no As String

Set olApp = CreateObject("Outlook.Application")

Set myNameSpace = olApp.GetNamespace("MAPI")

Set objFolder = myNameSpace.GetDefaultFolder(olFolderContacts)

Set objItems = objFolder.Items

For Each objItem In objItems

With objItem

If .Class = olContact Then

> OtherAddressCountry = "" ' This line works fine and other fields can also be updated

> Location = "" ' However this line generates runtime error 438


End If

End With

Not open for further replies.