Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel / Comma delimited problems 1

Status
Not open for further replies.

Cassaro

MIS
Jul 19, 2001
202
US
Greetings!

I am currently working on a large list of addresses with zip codes that I need to convert into a comma delimited format. The problem that I am having is the zip codes from a number of East Coast states start with the number "0". When I convert the Excel file to a comma delimited file it strips off the beginning "0" from the East Coast zip codes which creates errors when I import the list into our UPS machine. Any suggestion would be greatly appreciated.

Chuck
tek-tips@aspenpkg.com

If you feel a post has been helpful to you, click on the link at the bottom of their post to let them and others know the information was of use.
 
If you preceed the zip code with a single quote, such
as '01234, the file will be exported correctly.
However, if you import the same CSV file back into
Excel, the leading zero will be removed again.
 
I am not sure about the UPS machine and whether it will strip off the leading zero anyway, but have you tried setting the column with the zip codes up as TEXT only rather than GENERAL or NUMBER?

i.e. FORMAT -> CELLS -> TEXT

This will move all the zip codes to the left of the cell they are in.

The other option is setting up the column as ZIP. If you highlight the column, then FORMAT -> CELLS -> SPECIAL and choose ZIP CODE, it should put in the leading zeros, to a maximum of 5 characters.

That should work too.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top