View Single Post
Old 02-19-2013, 01:43 PM   #2
meme
Sigil developer
meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.meme ought to be getting tired of karma fortunes by now.
 
Posts: 1,275
Karma: 1101600
Join Date: Jan 2011
Location: UK
Device: Kindle PW, K4 NT, K3, Kobo Touch
I'm not aware of any way to generate a sequence of numbers using Regex.

I've been considering providing a tool or search option that allows this, for chapters and endnotes, so I'll put it on the Issues log as a request. It would probably be fairly simple though. Prompt you for a starting number and text to replace (e.g. "SEQUENCE#" or whatever text you type). Then it would just start from the first file and replace each occurrence with the number then increment, or possibly start from where you are in Code View to the end (no wrapping). You would have to convert all the text needing numbers to use "SEQUENCE#" or similar first - and in your case, run this twice since you use the number twice. I'd probably add Roman numerals as an option as well.
meme is offline   Reply With Quote