[Dropped] Find & Replace wildcard sequence

Not sure where to post? Post here!
Locked
elbraindead
Posts: 1
Joined: Sun Aug 11, 2013 6:07 am

[Dropped] Find & Replace wildcard sequence

Post by elbraindead »

I need to find & replace a number (ej: 100004) for a consecutive ascending sequence figure (ej: 100004 / 100005 / 100006 and so on).
I found that i can find any sequence of numbers with 6 digits (or more, but i need fixing a 6 digit) in the "find" slot by typing "[0-9][0-9][0-9][0-9][0-9][0-9]" but i cant seem to fill the "REPLACE" slot correctly so that the program replaces the 6 digit number for an ascending consecutive sequence.
Can anyone help me with this?

(sorry for my poor english its not my first language)
Last edited by MrProgrammer on Sat Mar 09, 2024 7:22 am, edited 1 time in total.
Reason: Dropped: No reply from elbraindead about Writer vs. Calc
OpenOffice 3.4 on Windows 7
User avatar
Hagar Delest
Moderator
Posts: 32650
Joined: Sun Oct 07, 2007 9:07 pm
Location: France

Re: Find & Replace Wildcards?

Post by Hagar Delest »

Hi and welcome to the forum!

You've posted in the Beginner section, it may help to know if you're working with Writer or Calc.
LibreOffice 7.6.2.1 on Xubuntu 23.10 and 7.6.4.1 portable on Windows 10
User avatar
RoryOF
Moderator
Posts: 34610
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Find & Replace Wildcards?

Post by RoryOF »

Also, do you wish to find and change the sequence into a different sequence (i.e., from 100004, 100005.... 100008 to say 876001, 876002... 876005)?
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
User avatar
acknak
Moderator
Posts: 22756
Joined: Mon Oct 08, 2007 1:25 am
Location: USA:NJ:E3

Re: Find & Replace Wildcards?

Post by acknak »

elbraindead wrote:... i cant seem to fill the "REPLACE" slot correctly so that the program replaces the 6 digit number for an ascending consecutive sequence. ...
Sorry, this is not possible with Find & Replace in OO. You would need to use an arithmetic expression in the replacement, and that is not supported.

If you are working in a Calc spreadsheet, you can do it easily, just not by Find & Replace. In Writer, not so easily--maybe by replacing the numbers with a "number range" field.
AOO4/LO5 • Linux • Fedora 23
User avatar
RoryOF
Moderator
Posts: 34610
Joined: Sat Jan 31, 2009 9:30 pm
Location: Ireland

Re: Find & Replace Wildcards?

Post by RoryOF »

If you wish to replace a sequence, provided the last digits are the same, you could find the first digits and replace them, leaving the last.
So 100004 could replace to 876004 etc.
Apache OpenOffice 4.1.15 on Xubuntu 22.04.4 LTS
Locked