Hi everyone... hoping you can help with a major head-scratcher (at least for me) I have a bunch of html text that I need to delete within a cell. In the sample I've attached, I want to remove all of the text after the first <br> (as well as that <br>) That should limit the size to each line to a very simple & short description, which is perfect.
I have about 2500 listings and doing this manually will take forever! Thank you for any input.
[Solved] Text within a cell: Remove <br> to end
[Solved] Text within a cell: Remove <br> to end
Last edited by Hagar Delest on Mon May 10, 2021 7:34 am, edited 1 time in total.
Reason: tagged solved.
Reason: tagged solved.
OpenOffice 4.1.0 on Windows 7
Re: Reducing text within a cell
First, make a copy of your file in case something goes wrong. Using the Edit -> Find & Replace dialog:
1. Enter
<br>.*$
in the Search For box.
2 Leave the Replace With box empty.
3. Click More Options and select Regular Expressions.
4. Click Replace All
1. Enter
<br>.*$
in the Search For box.
2 Leave the Replace With box empty.
3. Click More Options and select Regular Expressions.
4. Click Replace All
OpenOffice 4.1 on Windows 10 and Linux Mint
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
If your question is answered, please go to your first post, select the Edit button, and add [Solved] to the beginning of the title.
Re: Text within a cell: Remove <br> to end
Wow fantastic! Is there an additional figure you can use to reverse that formula ? (anything to the left of the <br> ) Hope you don't mind my asking, as you've definitely resolved the biggest part. Thanks again so much.
OpenOffice 4.1.0 on Windows 7
- Hagar Delest
- Moderator
- Posts: 32653
- Joined: Sun Oct 07, 2007 9:07 pm
- Location: France
Re: [Solved] Text within a cell: Remove <br> to end
I guess so but you need to provide more details (no attachment in your first post, limit the file size to 128KB maximum).
You can also see the help files about regular expressions (help button in the F&R dialog).
You can also see the help files about regular expressions (help button in the F&R dialog).
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
- MrProgrammer
- Moderator
- Posts: 4903
- Joined: Fri Jun 04, 2010 7:57 pm
- Location: Wisconsin, USA
Re: [Solved] Text within a cell: Remove <br> to end
Regular Expression matching <br> and all text to its left: ^.*<br>mrcastle wrote:[Remove] anything to the left of the <br>
Regular expression matching <br> and all text to its right: <br>.*$
You're really supposed to open a new topic for a new question after the original question has been solved.mrcastle wrote:Hope you don't mind my asking, as you've definitely resolved the biggest part.
If this solved your problem please go to your first post use the Edit button and add [Solved] to the start of the subject field. Select the green checkmark icon at the same time.
[Tutorial] Ten concepts that every Calc user should know
Mr. Programmer
AOO 4.1.7 Build 9800, MacOS 13.6.3, iMac Intel. The locale for any menus or Calc formulas in my posts is English (USA).
AOO 4.1.7 Build 9800, MacOS 13.6.3, iMac Intel. The locale for any menus or Calc formulas in my posts is English (USA).