Hi,
After reading all about Autonumber and what you should not do with them, I am building my DB from scratch. The problem that I immediately hit upon is as follows:
I created a table with a text field and want it to increment from 1 (so when the very first record is started the number 1 is already there).
I have tried putting the Dmax function in the default value, in VBA like this:
Private Sub IDNumber_BeforeUpdate(Cancel As Integer)
IDNumber = DMax("IDNumber", "Form_Input_Fam") + 1
End Sub
and many other methods. What am I doing wrong??
Thanks,
CG
After reading all about Autonumber and what you should not do with them, I am building my DB from scratch. The problem that I immediately hit upon is as follows:
I created a table with a text field and want it to increment from 1 (so when the very first record is started the number 1 is already there).
I have tried putting the Dmax function in the default value, in VBA like this:
Private Sub IDNumber_BeforeUpdate(Cancel As Integer)
IDNumber = DMax("IDNumber", "Form_Input_Fam") + 1
End Sub
and many other methods. What am I doing wrong??
Thanks,
CG