Finding text that may/may NOT have some garbage just before

General questions about using TextPad

Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard

Post Reply
User avatar
no.cache
Posts: 165
Joined: Thu May 15, 2003 2:52 pm

Finding text that may/may NOT have some garbage just before

Post by no.cache »

Hi Guys,

I'm making this big because the focus of the question is on punctuation.

My OCR'd text has a key point on each line where I'm trying to do some tidying. The lines look something like this:

unabbreviated text(space or spaces)SHERWOOD(space)KS(space or spaces)

unabbreviated text,(space or spaces)MONKEY(space)KS(space or spaces)

abbreviated text.(space or spaces)PETE(space)KS(space or spaces)

abbreviated text.,(space or spaces)ARCHIBALD(space)KS(space or spaces)

abbreviated text..,(space or spaces)WILLIAM(space)KS(space or spaces)


Those ALL CAPS WORDS are the ones that are the focus of the operation: Everything in red needs to consistently be a comma with one space:

,(one space)

Is there a way to clean up the missing/duplicated punctuation without harming those words that had to be abbreviated, whose periods need to remain in place? Example of the two options that I need:

unabbreviated text,(one space)SHERWOOD(space)KS(space or spaces)

abbreviated text.,(one space)PETE(space)KS(space or spaces)


Thanks again guys.

Skye
Post Reply