Leading Zeros

JEB

Registered User.
Local time
Today, 01:14
Joined
Dec 20, 2002
Messages
16
I am exporting a report from Access into Excel. One field has a store # - say 029. I need to have the leading zero in the field - but I can not get Excel to leave it there.

Any suggestions?

Thanks for the help.

Jeb
 
Last edited:
You need to make sure that the column in Excel that this item goes in is formatted as "Text"

Regards
Mark
 
Thanks for the reply.

The problem is that I would like it to export directly from Acess into Excel- without opening an Excel worksheet and formatting the cells.

Is there a way to have Excel recognize numbers as text when being exported?

Thanks,
Jeb
 
Just format your field in your query to export like this:
Num: Format(CStr([Number]),"000")
changing Num to whatever you want your column header to be
and [Number] to whatever your number field name is called.
 
Hello:

I tried Bobs solution and could not get it to work when I ran the query and exported it.

YourNewColumn: "000" & [YourNumberField]

in a query does work though

Regards
Mark
 
Didn't work for me. I am trying to export from an Acess REPORT - not just from the query. I don't know if that makes any difference

Thanks,
Jeb
 

Users who are viewing this thread

Back
Top Bottom