Search code examples
replacefindopenoffice.orgopenoffice-writer

How to replace certain character combination with another in OpenOffice?


I'd like to replace wrongly formatted text in multiple documents. Instead of the proper way like this

»Citation«

words have been cited like this

«Citation»

(or some other combination like »Citation»)

Now, I know there is the Regular Expression, which I'd use like this for the opening mark:

«[A-Z]

But how does the replace string look like? It doesn't work with "»", neither with "»[A-Z]", neither with "»*"....

I guess there is a very simple solution, but I haven't found any answer in the different forums. Thanks for any advice!


Solution

  • Search for:

    «([A-Z]+)»
    

    Replace with:

    »$1«
    

    For documentation, look under ( ) in the Character column at: https://help.libreoffice.org/Common/List_of_Regular_Expressions.