Search code examples
excelfindstreet-addressstring-length

Excel Formula to split address from name (=LEFT(A1,Find an Interager etc..))


This formula works on some of of my cells and not others, I've checked to see if the formatting was different but could find nothing.

I have for instance

a Cell that says "Dell Computers 12150 sandy dr portland or 97229"

What I want is just to get "Dell Computers" by itself.

I've tried a few things, the most obvious for mew as to:

=LEFT(A1,FIND({1,2,3,4,5,6,7,8,9,0},A1,1)-2)

This works for some, for others it doesn't (for some for instance the above if there are two 1's in the address it gives me "Dell Computers 1", taking the second 1 as being the value)

Maybe a newb question, but what am I doing?


Solution

  • use this function and set cell value to

    =udfRegEx(A1,"^\D+")