Hi redzan,
Thanks for the feedback.
One unusual thing about the macro is that is has these two lines:
.Execute Replace:=wdReplaceAll
.Execute
Ordinarily, you might not use the first one. In this case, however, I decided to do so on the premise that most of the converted paragraphs would have no more than a single space. If none has more than a single field with a space, the loop following the second line will never execute. However, if the initial reformatting gives something like:
###CHEST,BOZO, THE, CLOWN,02/27/2012,123456,WILL, SMITH,ADC
the first pass won't be sufficient and the loop will execute. It's more efficient this way and could make a noticeable difference in a really large document.
__________________
Cheers,
Paul Edstein
[Fmr MS MVP - Word]
|