Return text in a cell up to first number

sharkbot

New Member
Joined
Feb 13, 2004
Messages
15
I need to extract the first part of a cell that contains text. For example:

Kirk and Dunn 334 W.

I need to return just:

Kirk and Dunn

The same for when it looks like his:

Kirk and Dunn334

I need just:

Kirk and Dunn

Please help, I have been racking my brain for hours trying to figure this out. Thank YOU

Aaron
 

Excel Facts

Control Word Wrap
Press Alt+Enter to move to a new row in a cell. Lets you control where the words wrap.

Yogi Anand

MrExcel MVP
Joined
Mar 12, 2002
Messages
11,454
sharkbot said:
I need to extract the first part of a cell that contains text. For example:

Kirk and Dunn 334 W.

I need to return just:

Kirk and Dunn

The same for when it looks like his:

Kirk and Dunn334

I need just:

Kirk and Dunn

Please help, I have been racking my brain for hours trying to figure this out. Thank YOU

Aaron
Hi Aaron:

Welcome to MrExcel Board!

Let us have a look at ...
y040213h1a.xls
ABCD
1KirkandDunn334W.KirkandDunn
2KirkandDunn334KirkandDunn
Sheet3


This is according to your specs -- but I believe your specs need to be tightened a bit. Anyway, it should get us started.
 

sharkbot

New Member
Joined
Feb 13, 2004
Messages
15
Yogi you are a lifesaver!

Thanks so much. This is a great board. I can't believe how fast you replied. Thanks again, I am forever in debt to you.
 

Yogi Anand

MrExcel MVP
Joined
Mar 12, 2002
Messages
11,454
Aaron: You Are Very Welcome!

You may want to tighten up the spec a bit -- for example handling a case where there are no numerics in a string, or any other such eventuality that you think you may encounter in your real data.
 

Seti

Well-known Member
Joined
May 19, 2002
Messages
2,916
Also, if the data is "Kirk and Dunn 334", do you want/need the space after Dunn and before 334?
 
Learn Excel from Bill Jelen

Understanding data is crucial, and the easiest place to start is with Microsoft Excel.

Forum statistics

Threads
1,151,490
Messages
5,764,667
Members
425,228
Latest member
Rashid mahmood

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top