View Single Post
 
Old 05-26-2011, 03:34 PM
macropod's Avatar
macropod macropod is offline Windows 7 32bit Office 2007
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 21,963
macropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond reputemacropod has a reputation beyond repute
Default

Hi AtaLoss,

That's a limitation of using 'MatchAllWordForms = True' - it only accepts letters. One way to handle this would be to force the Find/Replace to use both 'MatchAllWordForms = True' and 'MatchAllWordForms = False'. For example, add:
On Error Resume Next
before:
For i = 0 To UBound(Split(StrFnd, ","))
and insert:
.MatchAllWordForms = False
.Execute Replace:=wdReplaceAll
after:
.Execute Replace:=wdReplaceAll
This will pick up the words with apostrophes, but not the apostrophe and whatever follows it - unless you put the apostrophe and whatever follows it into the array.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
Reply With Quote