Calc: How to replace linebreaks in a set of cells with the space char

I wish to convert two lines of text per cell into one line of text (with a space character separator) in each cell.

I selected all the cells needing change; selected Find & Replace;

entered “\n” into the Find field and " " (the space char) into the Replace field;

ticked: Current selection only, & Regular expressions;

and chose Replace All.

It worked.

I apologise for the Question.
However my mistake may be of relevance to others.
I had initial problems with the text I was working on. Some of the text following the line break was in brackets (), and I used it to help localise the Find & Replace, but I was unaware that () were also special chars in Regular Expressions. and had to disable them with "\" (the back slash). This was what confounded me for some time.

I would like to suggest that a revised description/explanation be given for the use of regular expressions and wild cards in LibreOffice - their potential, limitations, and dangers.
Maybe a tutorial, revisions in the Help system, added documentation in the manuals???

Thank you for these tools and the opportunity to explore them.
Willem Lindemans

LeroyG added preformatted text code to show the back slash.

trick in calc-libreoffice to remove broken lines (ctrl+enter) in cells

  • activate regex (options/calc/activate_expres.regular)

buscar (expres.regular)–> [^[:print:]]
reemplazar–> (insert a space)

note: ([:print:] = Any printable character (set defined by alnum and punct)
plus the single character SPACE.)