[Solved-Workaround] Create page breaks with Find&Replace

Discuss the word processor
Post Reply
vercingetorix2012
Posts: 1
Joined: Wed Jul 26, 2023 3:46 pm

[Solved-Workaround] Create page breaks with Find&Replace

Post by vercingetorix2012 »

Hello, i need some help.
Every day i receive a xml file from an application and must separate text with manual page breaks.
In Microsoft Office i select separator and replace with manual page break character defined in office, using function "find and replace''.
In Open Office i cannot find the character for manual page break, i.e. " ^m ".
I read help online and only solution was to insert manual ctrl+enter, but my file has 30-40 pages, it's useless for me.
I attach some print screen, thanks very much.
samplex new.jpg
samplex new.jpg (125.98 KiB) Viewed 3312 times
sample1 new.jpg
sample1 new.jpg (124.65 KiB) Viewed 3312 times
sample2 new.jpg
sample2 new.jpg (126.16 KiB) Viewed 3312 times
Last edited by MrProgrammer on Wed Aug 09, 2023 6:05 pm, edited 1 time in total.
open office 4.1.14 windows 11 64 bit
User avatar
robleyd
Moderator
Posts: 5509
Joined: Mon Aug 19, 2013 3:47 am
Location: Murbko, Australia

Re: how to insert multiple page breaks in document

Post by robleyd »

Writer doesn't have that feature but there is an extension Alternative dialog Find & Replace for Writer which can help you.
Slackware 15 (current) 64 bit
Apache OpenOffice 4.1.16
LibreOffice 26.2.3.2; SlackBuild for 26.2.3 by Eric Hameleers
---------------
I hate this damn computer, I wish that I could sell it.
It won't do what I want it to, Only what I tell it.
User avatar
keme
Volunteer
Posts: 3791
Joined: Wed Nov 28, 2007 10:27 am
Location: Egersund, Norway

Re: how to insert multiple page breaks in document

Post by keme »

A workaround that may be of use:
  • Create a new paragraph style based on the one which is in use (most likely either Default or Text body)
  • In the Text flow tab, tick the option to insert break, and select page break before.
  • OK
  • Select Edit - Find and replace ...
  • Enter your search term
    If the mark for new page is two tabs on an otherwise empty line, use regular expression ^\t\t$
    Regular expressions must be ticked under More options for this search to work
  • Click Find all
  • Double click the paragraph style entry you created to apply it to the matches.
If you keep your file with the paragraph style as a template for future work, next time the job will be just find and apply, which is little more than find and replace.

Page breaks in Writer do not exist as separate entities, they are a format property for the first (breaking) paragraph on that page, so applying that style should be functionally the same as your pressing ctrl+enter.
JeJe
Volunteer
Posts: 3132
Joined: Wed Mar 09, 2016 2:40 pm

Re: How to insert multiple page breaks in document

Post by JeJe »

As an xml file is a text file you could edit it directly - in Writer or any basic text editor. There is a free online version of Word if you need a feature Writer hasn't got - and many other Word processors online to look for, including free ones, which might also support it.
Windows 10, Openoffice 4.1.11, LibreOffice 7.4.0.3 (x64)
Post Reply