Affichage des articles dont le libellé est Dmax for empty table. Afficher tous les articles
Affichage des articles dont le libellé est Dmax for empty table. Afficher tous les articles

Dmax for empty table

mercredi 15 avril 2015

How do i use DMax() function instead of Autonumber, since the table is empty and it wont know what to do with Dmax() + 1 for next record?



E.g I have a new table Customer_details which contains



customerID

customerName

Age



now if i enter data through forms, i want the CustomerID to be incremental for each new record, so i can use Dmax() function. But since the table is empty how can i tell the form, through VBA that if it is null store 1 else store Dmax("CustomerID", "Customer_Details") + 1

Dmax for empty table

Labels