Re: Need to extract all digits from string

2021-07-29 Thread Christopher Stone
On Jul 29, 2021, at 00:19, Tim A wrote: > How to not include the brackets as Howard asked? I figure it involves > non-capture but it eludes me. Eh? Hmm. I must have been tired. Find: \[(\d+)\]|(\d) Replace: \1\2\n -- Best Regards, Chris -- This is the BBEdit Talk public discussion

Re: Need to extract all digits from string

2021-07-29 Thread Donald Goyette
Find: (\d)|\[(\d{2})\] Replace: \1\2\n (or just \1\2 if using "Extract") Either \1 or \2 will be empty, so no harm in including both in the replacement. On 29 Jul 2021, at 1:19, Tim A wrote: > How to not include the brackets as Howard asked? I figure it involves > non-capture but it eludes

Re: Need to extract all digits from string

2021-07-29 Thread Tim A
How to not include the brackets as Howard asked? I figure it involves non-capture but it eludes me. -- This is the BBEdit Talk public discussion group. If you have a feature request or need technical support, please email "supp...@barebones.com" rather than posting here. Follow @bbedit on

Re: Need to extract all digits from string

2021-07-28 Thread Howard
Regmatches is a term in R programming. Sorry if it caused confusion. On Tuesday, 27 July 2021 at 5:52:38 pm UTC-4 listmei...@gmail.com wrote: > Hey Howard, > > What exactly do you mean by “regmatches”? > > Find: > > (\d|\[\d+\]) > > Replace: > > \1\n > > -- > Best Regards, > Chris > >

Re: Need to extract all digits from string

2021-07-27 Thread Christopher Stone
Hey Howard, What exactly do you mean by “regmatches”? Find: (\d|\[\d+\]) Replace: \1\n -- Best Regards, Chris > On Jul 27, 2021, at 14:41, Howard > wrote: > > I have a string of numbers like this: > > "12[11]4567[10]0" > > The string may be longer or

Need to extract all digits from string

2021-07-27 Thread Howard
I have a string of numbers like this: "12[11]4567[10]0" The string may be longer or shorter than the one shown above. The numbers within the brackets always contain two digits. I need to extract the numbers so they appear like below, each number a separate element. The format does not have to