keeping leading 0's when formatting cells

J

James

I am currently writting a small macro but ran across some trouble when
seperating a numbers in a cell that have leading zero's. Below is an example
of one of the cells that I have.

00000001 00005212 00012312

I have tried converting the column to a "text" format but cannot keep the
leading zero's there when I do a text to column, making a new column when
there is a space. I know if I put a " ' " it will keep the leading zero's
but how can I apply that to all the data in that column. or is there some
better way to keep the leading zero's in the cells once they are seperated
into 3 different columns.

Thanks for the help.
 
G

Gord Dibben

When running though the Text to columns wizard, in step 3 designate each column
as Data Type>Text


Gord Dibben MS Excel MVP
 
J

James

I always rush on the text to column items I have never seen step 3. That is
exactly what I need. Thanks.
 

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