Skipping Blank Lines?
-
I have 7253 lines. I need to have all the words in a paragraph on one line. I made a macro will move all words in a paragraph, but i need to skip the empty/blank lines that seperate paragraphs.
- “Doss,” said Mrs. Stirling, “what do you mean by taking off your hat? Put it on instantly!”
- Valancy put it on instantly. She was cold with fear lest Dr. Stalling should immediately summon her up front again.
I need my macro to skip line 2 in the example above. Can this be done?
-
only if the pattern would be the same over the whole text otherwise
you would need some regex or script to do the job. Or you find some similarity
and, maybe, can use bookmarks !?Cheers
Claudia -
You may try the following RegEx for searching:
(?<=\w)\R(?!\R). Replace with empty Text. This will remove any line break preceded by a word character and not followed by another line break. You may also try\S(non-space-characters) for\w. -
Search:
\s+(.*?)Replace with:
(Leave one Space)Or another solution:
Search:
\R
Replace by:
(Leave one space)
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login