Date: prev next · Thread: first prev next last
2013 Archives by date, by thread · List index


I thought it would be much easier. Writing a macro is not worth the effort in my case. I'm not going to use it very often. I think I will stick to regex and delete temporally all line brake marks to make a text one single and continuous paragraph for a moment. It requires few more operations on regex but is still easier and faster way then writing a macro.
Thank you very much for your help. Regards,
gordom


W dniu 2013-11-26 17:35, Kracked_P_P---webmaster pisze:

You know that you need to go to Find/Replace and choose "more options"
to get to the regular expressions, correct?

Now the problem you have is something that is more of a macro and not a
find/replace with "regex".

You have to find the first word and then mark that text placement.  Then
find the second word and mark that text placement.  At that point you
need to highlight all the text between those text placements.

My question is . . .
Are you going to do this many times or only once or twice?

If you so not need to do this ofter, I would use the Find option and
write down the line/column/etc. of the word.  Then I would search for
the second word.  At that point I would go back to the first word's
position and highlight al the text till I get to the position of the
second word.

I see no way to do something like this outside of a macro and I do not
know macros so I could not tell you how to do this.  I might be able to
write a Pyhton script to do the work, but that would not be something
you would do inside Writer.


On 11/26/2013 10:42 AM, gordom wrote:
Hallo everyone.
I can't figure out how to write a regex to find all text in between
certain words. The problem I have is related to line break marks.
These two words belong to different paragraphs and therefore the text
I'm looking for consists of numerous line break or paragraph break
marks. Here you have a sample of the text:

Lorem ipsum dolor sit amet, consectetur adipiscing elit.
Nam convallis nisi lorem, sit amet sagittis tortor interdum a.
abc123    Integer facilisis nisl ut est commodo varius. Integer
luctus massa in ultrices scelerisque. Pellentesque

scelerisque velit ullamcorper libero tempor dapibus a nec risus.
Pellentesque vehicula, erat id mollis tempus, lorem lacus
congue dolor, id interdum est diam ac felis.    xyz
Nunc a tincidunt massa, vitae placerat urna. Suspendisse potenti.

Let say the text, I'm looking for, follows abc123 and goes before xyz.

Of course I can temporally replace all line break marks with some
other character and use a regex like this one for example:
abc123.+xyz. It works but I would like to find a straight way to do
it. Any help will be appreciated.
Best regards,
gordom





--
To unsubscribe e-mail to: users+unsubscribe@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.