Extracting part of Text from one cell to another
Try this ( works on my testing assuming single blanks as delimiters)
Assuming data in A2
in B1:
=LEFT(A2,SEARCH({1,2,3,4,5,6,7,8,9,0},A2& "1,2,3,4,5,6,7,8,9,0")-1)
Enter the following with Ctrl+Shift+Enter (array formulae)
in C1:
=VALUE(MID($A2,SUM(LEN($B2:$B2))+1,FIND("
",$A2,SUM(LEN($B2:$B2))+1)-SUM(LEN($B2:$B2))-1))
in D1:
=VALUE(MID($A2,SUM(LEN($B2:$C2))+2,FIND("
",$A2,SUM(LEN($B2:$C2))+2)-SUM(LEN($B2:$C2))-2))
in E1:
=VALUE(MID($A2,SUM(LEN($B2:$D2))+3,FIND("
",$A2,SUM(LEN($B2:$D2))+3)-SUM(LEN($B2:$D2))-3))
in F1:
=VALUE(RIGHT($A2,LEN($A2)-(SUM(LEN($B2:$E2))+3)))
HTH
"JayW" wrote:
Simple I thought, but can anyone help
I have a column of cells with similar to the following text.
First Marine Avenue 18 1303 11 1
There will always be a final 4 groups of text numbers, each with a space
between, but each having different number of numbers (this particular
sequence has 2,4,2,1 - but others may be different, but always 4 groups)
The true text ( a series of Road names are potentiaaly all different, having
a sequence of words that may be up to 5 words long before the numbers start)
I need to extract the 4 groups of numbers into seperate cells, leaving the
Road name text in a singe cell. I would then have a table of 5 columns, the
first the Road text, and the next 4 columns being the group of numbers, which
I would then format as numbers.
--
JayW, Hants, UK
|