![]() |
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. |
|
|
Thread Tools | Search this Thread | Display Modes |
#1
|
|||
|
|||
![]()
I'm trying to update a routine that will update out Outlook Recipients
lists with an employee database. I've added a custom field to the contacts called EMPID. What I would like to do is search the contacts for a specific Employee ID (EMPID) and then update it with the information from the database. I'm unable to search on this field apparently: Error: -659423223 The property "EMPID" is unknown. Dim myFolder As Outlook.MAPIFolder Dim myNameSpace As Outlook.NameSpace Dim myOutlook As Outlook.Application Dim myPublicContact As Outlook.ContactItem Set myOutlook = CreateObject("Outlook.Application." & Val(Left (Outlook.Version, 2))) Set myNameSpace = myOutlook.GetNamespace("MAPI") myNameSpace.Logon Set myFolder = myNameSpace.Folders("Public Folders").Folders("All Public Folders").Folders("Contacts").Folders("Recipients List") Set myPublicContact = myFolder.Items.Find("[EMPID] = ""472""") |
Ads |
#2
|
|||
|
|||
![]()
Ok, I finally found the answer. I had been searching for awhile
before posting, then I posted and continued to search, and found the answer. I had to create the UserProperty for the folder, not on a specific item. I did this and went to a user and the property wasn't there. It was in the folder view that I had, so I just went down the list and added the value and then it was searchable. Pretty odd... Anything else I should know about this? |
#3
|
|||
|
|||
![]()
You can also use the SQL syntax when calling Find and specify the property
name in the DASL format -- Dmitry Streblechenko (MVP) http://www.dimastr.com/ OutlookSpy - Outlook, CDO and MAPI Developer Tool - "McKilty" wrote in message ... Ok, I finally found the answer. I had been searching for awhile before posting, then I posted and continued to search, and found the answer. I had to create the UserProperty for the folder, not on a specific item. I did this and went to a user and the property wasn't there. It was in the folder view that I had, so I just went down the list and added the value and then it was searchable. Pretty odd... Anything else I should know about this? |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
searching contacts | biggie | Outlook - Using Contacts | 5 | May 19th 08 09:06 PM |
Searching contacts using keystrokes | Tony[_4_] | Outlook - Using Contacts | 0 | February 28th 08 03:37 PM |
Searching Notes in Contacts | nikitab | Outlook - Using Contacts | 4 | February 8th 08 11:38 PM |
trying to move contacts-searching did not help | bspeed | Outlook - Using Contacts | 1 | January 9th 08 01:48 PM |
Searching Contacts and sub folders | MCA | Outlook - Using Contacts | 2 | January 19th 06 08:26 AM |