HELP with Leading Zero

G

Guest

I am using a program called ID works to make ID badges for our facility. We
are changing the configuration of the barcode to 10 digits with the first 4 -
5 digits being a zero.
The access database is not holding the zeros in the table when the data is
saved.
The table is set to be text, with 10 digits. Does anyone have any help?
 
J

Joseph Meehan

Charlynn said:
I am using a program called ID works to make ID badges for our
facility. We are changing the configuration of the barcode to 10
digits with the first 4 - 5 digits being a zero.
The access database is not holding the zeros in the table when the
data is saved.
The table is set to be text, with 10 digits. Does anyone have any
help?

Numbers do not have leading zeros. If it is a number field it will not
save a leading zero. There are two ways to get what you want. One is to
format the forms and or reports where you will display the numbers and you
want then to appear with the leading zeros. The other is to change the
field type to text and then add the leading zeros. Access will save leading
zeros if they are in a text field.

Remember that changing from number to text changes the way they will be
sorted.
 
B

B_A_R_T_M_A_N

If it is a text field, you could of done a format statement:

Badgeid = format(ID,"00000")
 

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