Hi Joanne,
You have your search string wrong. It's actually looking for the ampersand,
a space, Chr(32). You also haven't specifically started a wildcard search.
Try the following instead:
With Selection.Find
.ClearFormatting
.Text = "; {1,}"
With .Replacement
.ClearFormatting
.Text = "Hello"
End With
.MatchWildcards = True
.Forward = True
.Wrap = wdFindContinue
.Execute Replace:=wdReplaceAll
End With
HTH,
Dave
> Hello, I wrote the following code to replace any instance of a semi colon and
> one or more spaces following, but it doesn't seem to do anything. No errors,
[quoted text clipped - 18 lines]
>
> End Sub
Joanne - 28 Feb 2005 21:23 GMT
Thank you, it worked!
> Hi Joanne,
>
[quoted text clipped - 42 lines]
> >
> > End Sub