How do I auto number using 01, 02 instead of just 1, 2 etc

P

paste2

I'm working w/jpeg files that are associated w/my database. I need to store
the jpegs using 01,02, etc. as file names. I have a VBA code that links the
Item No. to the Jpeg file name and runs a report w/data and a photo.

I can't get Access to let me number the items using the same numbers. It
only allows for 1, 2, etc. I don't want to store 2 sets of photos just
because of file names. Can someone help me renumber the DB?
 
R

Roger Carlson

You can't use autonumbers reliably for this. You will develop gaps that
cannot be recovered and you can't format them either. The best way is to
create your own numbering scheme. On my website
(www.rogersaccesslibrary.com), there is a small Access database sample
called "AutonumberProblem.mdb" which uses the DMax() function to find the
highest number existing in a table and add 1 to it. With a little bit of
adaptation, you should be able to make it work in your case.

--
--Roger Carlson
Access Database Samples: www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L
 

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