Hi,
So I am relatively new to VBA etc so please be gentle...
I am trying to automate the generation of a reference number incrementally by 1.
In my main table (tblBooking) I have my primary key field autBookingID which is an autonumber.
In another table (tblBookingStops) I have the primary key as autBookingStopsID as the autonumber and then numBookingID linked to the above table (tblBooking). I have another field called txtGPSID so this is the number I would like to automate.
So for example:
tblBooking:
autBookingID: 1234
tblBookingStops:
autBookingStopsID: 5555
autBookingID: 1234
txtGPSID: 1234.1
autBookingStopsID: 5555
autBookingID: 1234
txtGPSID: 1234.2
autBookingStopsID: 5555
autBookingID: 1234
txtGPSID: 1234.3
I want to put the code that would populate the txtGPSID on a form in datasheet view and would like to put the code on the load event.
Hope that was enough to go by and that I was clear enough.
Thanks
Ant
So I am relatively new to VBA etc so please be gentle...
I am trying to automate the generation of a reference number incrementally by 1.
In my main table (tblBooking) I have my primary key field autBookingID which is an autonumber.
In another table (tblBookingStops) I have the primary key as autBookingStopsID as the autonumber and then numBookingID linked to the above table (tblBooking). I have another field called txtGPSID so this is the number I would like to automate.
So for example:
tblBooking:
autBookingID: 1234
tblBookingStops:
autBookingStopsID: 5555
autBookingID: 1234
txtGPSID: 1234.1
autBookingStopsID: 5555
autBookingID: 1234
txtGPSID: 1234.2
autBookingStopsID: 5555
autBookingID: 1234
txtGPSID: 1234.3
I want to put the code that would populate the txtGPSID on a form in datasheet view and would like to put the code on the load event.
Hope that was enough to go by and that I was clear enough.
Thanks
Ant