Excel default formatting of numbers

R

R2DJ

I have a CSV file which is generated by an inhouse application. One of
the columns in this file has a four digit code, which are text but made
of numerical digits. Some of the codes start with one or more zeroes,
ie 0012, 0013, 0014 etc. The problem is when my users open the file in
Excel the column has been formatted as numbers and the leading zeroes
have been trimmed, so 0013 becomes 13. I do not want my users to have
to play around with formatting. Also even if I do select the column and
change the formatting to text the leading zeroes are still missing.

Please could anyone help me with a solution.

Ta.



------------------------------------------------




------------------------------------------------
 
D

Dave Peterson

How about renaming your .csv file to .txt?

Then record a macro while you import the file. You'll see the import text
wizard and you'll be able to force that field to be text (keeping the leading
0's).

Then distribute this macro workbook to your users.

You could even make the macro more useful. Add headers/filters/subtotals/print
setup. They might even like this better.
 

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