Switchboard button +1

S

Sharon

I have a switchboard button that is "Add Receipt". When I select this from
the switchboard, i would like to the form to come up with the last
"ReceiptNum" +1.
The table is tblReceipt, which consists of ReceiptID (PK, Autonumber),
ReceiptNum (Text Field), etc. The ReceiptNum is RE060001, RE060002, etc.
When the "Add Receipt button is selected, I would like the ReceiptID to
automatically insert the last ReceiptNum + 1.
 
T

Tom Lake

Sharon said:
I have a switchboard button that is "Add Receipt". When I select this from
the switchboard, i would like to the form to come up with the last
"ReceiptNum" +1.
The table is tblReceipt, which consists of ReceiptID (PK, Autonumber),
ReceiptNum (Text Field), etc. The ReceiptNum is RE060001, RE060002, etc.
When the "Add Receipt button is selected, I would like the ReceiptID to
automatically insert the last ReceiptNum + 1.

If you don't store thr "RE" in the table and make the rest a numeric field,
you can use Max to find the highest number in the table and then add one.

Tom Lake
 
Top