How to extract just text from cells

A

Access Joe

Hi all,

I want to extract only TEXT from a column of numbers and text. For example:

WHAT I HAVE:
150mgdl
2000mg
10mgdl
500cc

WHAT I WANT:
mgdl
mg
mgdl
cc

is there a function in Excel that does this and extracts only the text, not
the numbers?

Thanks everyone!
 
R

ryguy7272

Try this:
=MID(A15,SUMPRODUCT(--ISNUMBER(--MID(A1,ROW($1:$999),1)))+1,999)


Regards,
Ryan--
 
R

ryguy7272

This shoudl work as well:
Function RemDigits(str As String) As String
Dim re As Object
Set re = CreateObject("vbscript.regexp")
re.Global = True
re.Pattern = "\d+"
RemDigits = re.Replace(str, "")
End Function

Regards,
Ryan--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top