Skip to main content
Inspiring
June 18, 2020
Answered

Find missing space between period and text

  • June 18, 2020
  • 2 replies
  • 739 views

With the basic search command (with regular expression checked), I could able to find the instances where there is period followed by any word or number by the expression \.\w And with the expression \.\u I could able to find period followed by an upper case letter (preferred) without space in between.

But in the replace window if I give \.\s\u it doesn't work. It replaces the capital letter with the letter 'u'.

  1. I suppose if I write a extendscript it may work. Or
  2. Is there a way to add the expression \.\u for the auto spell check to find, thus a red squiggle will appear on these instances?

 

This topic has been closed for replies.
Correct answer frameexpert

You need to "capture" parts of your regular expression matches with parenthesis so you can restore them in the Change field.

 

Find: (\.)(\u)

Change: $1 $2

2 replies

Barb Binder
Community Expert
Community Expert
June 22, 2020

You can also tell Fm to flag two words with a period but no space in between by disabling Words Containing . in Edit > Preferences > Spelling Options. When you right click over the squiggle, Fm will offer the correction with the space.

 

But I'd use the RegEx that Rick provided as part of the document clean-up if you have a typist who repeatedly forgets to add spaces between sentences.

 

~Barb

~Barb at Rocky Mountain Training
frameexpert
Community Expert
frameexpertCommunity ExpertCorrect answer
Community Expert
June 18, 2020

You need to "capture" parts of your regular expression matches with parenthesis so you can restore them in the Change field.

 

Find: (\.)(\u)

Change: $1 $2

www.frameexpert.com