Ask Your Question
0

How can I remove double carriage returns?

asked 2016-01-25 23:10:56 +0200

BobD gravatar image

updated 2016-03-10 13:41:25 +0200

Alex Kemp gravatar image

I have a long OCR-generated document with a carriage return at the end of each line and two carriage returns at the end of each para. I want to make the text in each para wrap around by replacing the double carriage return by (arbitrarily) *, replacing the remaining carriage returns by a space, and then restoring the paragraph breaks by changing * back to two carriage returns. What should I use to indicate two carriage returns in the Find/Replace box? §§ doesn't seem to work. I'm using LibreOffice 5.0.3.2 with Mac OS 10.11.1, and have the Alternative Searching 1.4.1 extension installed.

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
1

answered 2016-01-26 16:49:50 +0200

pierre-yves samyn gravatar image

updated 2016-01-26 16:51:29 +0200

Hi

If I understand you can do this by 3 EditFind & Replace:

Other options: check Regular expressions

  • Search For: ^$
  • Replace With (something not occurring anywhere else in the text, like): µµµ
  • Replace All

  • Search For: $

  • Replace With: Space
  • Replace All

  • Search For: µµµ

  • Replace With: \n\n
  • Replace All

Regards

edit flag offensive delete link more

Comments

Thanks, that's done the job.

BobD gravatar imageBobD ( 2016-01-27 12:56:59 +0200 )edit
Login/Signup to Answer

Question Tools

2 followers

Stats

Asked: 2016-01-25 23:10:56 +0200

Seen: 1,189 times

Last updated: Jan 26 '16