Quote:
Originally Posted by droopy
Hi Ducks,
your code works for
C. S. Lew --> CS Lew
But for Charles Q. Smith
it becomes
Ch arles Q. Smith
(space between h and a. And dot after Q. isn't removed).
Bob T. Johnson --> Bo b T. Johnson
Bob A. B. Johnson --> Bo b A. B. Johnson
|
I gave you code for C. S. Lewis ( type case), just what you asked for

(I did not even
try to develop a general REGEX.
Again:
Why not use the Quality Check Plugin: to detect and FIX (that is where you also set the initials pattern desired)?
I run the detect (Check Authors initials), then run Fix on the reviewed-selected results (there are some cases to NOT fix)