A
AnnieB
Hi there!
I have a table of Assessors [TblAssessors] and a field [RegNo] which is
filled in later when trainees have successfully passed. This is later used on
a Certificate of Registration. As not all trainees will successfully
complete, I'd like to create a macro that will assign an incremental [RegNo]
on a button's click event on my data entry form "FrmAssessors".
Unfortunately, I have inherited this data and [RegNo] is in the format of
"QTA00101","QTA00102", etc. The prefix will always be "QTA" and at this stage
we do not envisage ever needing more than 5 digits to follow.
I seem to recall seeing a post somewhere on this site a while ago regarding
something similar but I can't locate it now.
I believe it dealt with creating a table to store the last used number and
when executed, the code looks up that table, increments the stored number by
1, writes it to the formfield and then stores the new number back in the
number storage table.
Have I got that right? Is it possible to do in this case with the QTA prefix?
Anyone have some code that might help?
Any help most gratefully received!
I have a table of Assessors [TblAssessors] and a field [RegNo] which is
filled in later when trainees have successfully passed. This is later used on
a Certificate of Registration. As not all trainees will successfully
complete, I'd like to create a macro that will assign an incremental [RegNo]
on a button's click event on my data entry form "FrmAssessors".
Unfortunately, I have inherited this data and [RegNo] is in the format of
"QTA00101","QTA00102", etc. The prefix will always be "QTA" and at this stage
we do not envisage ever needing more than 5 digits to follow.
I seem to recall seeing a post somewhere on this site a while ago regarding
something similar but I can't locate it now.
I believe it dealt with creating a table to store the last used number and
when executed, the code looks up that table, increments the stored number by
1, writes it to the formfield and then stores the new number back in the
number storage table.
Have I got that right? Is it possible to do in this case with the QTA prefix?
Anyone have some code that might help?
Any help most gratefully received!