Does that answer your question?
i guess i could work with that
you can try like
Code:
mypath = "c:\test\" 'change to suit
fname = dir(mypath & "*.doc")
do while len(fname) > 0
set doc = documents.open(mypath & fname)
pos = instr(fname, ",")
if pos > 0 then
repl = "Mr " & left(fname, pos - 1)
doc.Content.Find.Execute "<names>", , , , , , , , , repl, wdReplaceAll
doc.close true
end if
fname = dir
loop
this would assume that all clients are male, that all doc file names in the folder are in the format "Doe,Fred.doc"
filenames not containing "," will be ignored
i did not test this