View Single Post
  #2  
Old May 9th 06, 11:25 PM posted to microsoft.public.outlook.program_addins
Dave Kane [MVP - Outlook]
external usenet poster
 
Posts: 33
Default Search for contact item with double quotes in Name

Create your search string like this, specifying the ASCII character for the
double-quote and using a single-quote to delimit the value of the field you
are searching on.

strSearch = "[FileAs]='Smith, David " & Chr(34) & "Home" & Chr(34) & "'"
"Dave" wrote in message
...
Is there any way to search for an Outlook contact item that has double
quotes in there Name/FileAs field ?

The FileAs field has like - Smith, David "Home"

Dim fldrs As Outlook.MAPIFolder
Dim SearchItem As Outlook.ContactItem

' this assignment doesn't work in VB as written, but I'm just trying to
represent the string
' I'm searching for
strSearch = "[FileAs] = "Smith, David "Home""

Set SearchItem = g_fldr.Items.Find(strSearch)







Ads