Input Mask/AutoNumber (1 Viewer)

LKE

New member
Local time
Today, 02:24
Joined
May 3, 2002
Messages
6
Hi....

Is there a way to create an input mask in conjunction with an AutoNumber?

For example:

ID number: bm-1001-02
next ID: SL-1002-02
next ID: bm-1003-01

Basically, I would like Access to increase the middle number by 1 for each new record added, but the first 2 and the last 2 characters will vary depending on the type of record I am creating. Is there a way to do this??

Thanks very much!!!
 

David R

I know a few things...
Local time
Yesterday, 20:24
Joined
Oct 23, 2001
Messages
2,633
Use three different fields. Since the three pieces of data are determined differently (1st piece by some other criteria, 2nd by autonumber, and 3rd by a separate criteria), you should not store them in one field. You can display them in one field later on for forms and reports and the like by using the concatenation operator, &.

Also, beware of storing the 1st and 3rd parts if they're uniquely determined by other data on the form. Don't store the same thing 'twice', effectively, if you can determine it with a query field or an unbound form control.
 

Users who are viewing this thread

Top Bottom