Extract number between a dash

E

Eric

Hello,

Is there a way to extract numbers from a cell? Basically I have a list of
APN numbers, sometimes they include letters but they are always broken with a
dash. I need to extract the three different sections of the APN number into 3
different cells. For example APN number:

123A-456-789

Needs to be broken up into the following cells as follows:

B1: 123A
C1: 456
D1: 789

As i mentioned earlier numbers and sizes can change, the only constant is
the dash. Thanks for your help.
 
A

AccessHelp

You can try "Text to Columns" under Data on the menu bar.

On the first screen of Text to Columns, select "Delimited". On the 2nd
screen, check the box (and uncheck all other boxes under Delimiters)
"Other:", and type in a dash the box next to Other:. On the third screen,
you can define the data format (Text, Date, etc.) for each delimited column.

I hope that helps.
 
G

Gord Dibben

Data>Text to columns>dleimited by other. Enter a hyphen and Next>Next

Column Data Format>Text..........this to prevent dropping of leading zeros, if
any)

Finish.


Gord Dibben MS Excel MVP
 

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