General information
Category:
COM/DCOM and OLE Automation
Title:
How to update Outlook 98 Contacts in Public Folders
I know how to access the Outlook Contacts list but i don't know how to
update info in it.
For expl:
loOutlook = CREATEOBJECT('Outlook.Application')
loNameSpace = loOutlook.GetNameSpace('MAPI')
loContacts = loNameSpace.folders('Public Folders').folders('All Public
Folders').folders('Pacom-Bell Contacts')
wait window 'Found ' + allt(str(loContacts.items.COUNT)) + ' contacts in
'+loContacts.NAME + ' folder ' timeout 2
ContactsMob = 0
nUpdated = 0
FOR j = 1 TO loContacts.items.COUNT
IF !EMPTY(loContacts.items.ITEM[j].MobileTelephoneNumber)
if loContacts.items.ITEM[j].MobileTelephoneNumber = '0011 '
lcMobileNo = STRTRAN(loContacts.items.ITEM[j].MobileTelephoneNumber,'0011
', '+')
loContacts.items.ITEM[j].MobileTelephoneNumber = lcMobileNo
loContacts.items.ITEM[j].save
nUpdated = nUpdated + 1
wait window 'Total contacts with Mobile No.s with 0011 replaced with + is
' + allt(str(nUpdated)) + ' in '+loContacts.NAME + ' folder ' nowait
exit
endif
oBject.Save or oBject.Update dosn't work .
I want to update field MobileTelephoneNumber and some other fields.
I made sure that have read/write access to this folder by network admin.
Can somebody help?
Thanks
Regards
Dejan
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only