my access-application, I have a selection of "word"-documents. I want to look for a word/string within these documents and make a smaller selection with only those documents that contain that particular word/string
The corresponding code in a loop I use is:
dim SelectedMap, NameOfDocument, SearchString as String
Dim Exists as Boolean
SelectedMap = ...
NameOfDocument = ...
SearchString = ...
With Application.FileSearch
.NewSearch
.LookIn = SelectedMap
.SearchSubFolders = False
.FileName = NameOfDocument
.MatchTextExactly = True
.TextOrProperty = SearchString
.FileType = msoFileTypeWordDocuments
'.FileType = msoFileTypeAllFiles
Exists= .Execute(, , True) > 0
End With
This works fine with ordinay words such as "news" "probably" ..
This doesn't work with strings containing "." or ","
for eaxample "2.2.6", I get wrong results (with or without wildcards)
Does anyone know a solution ?
I'd be very grateful
dammato