mainrotor
asked on
I need assistance saving on a click event in ACCESS 2013
Hi Experts,
I need to save a record in an ACCESS 2013 to my tblJOb table on a button click event. When I save the record using a VBA sql query, I want it to return The JobID (auto generated key) that was given to the newly created record. How can I do this? These are my table fields:
tblJob has the following fields:
JobID (Primary key - auto generated)
JobName
COntactName
ContactPhone
ContactEmail
thank you very much in advance,
mrotor
I need to save a record in an ACCESS 2013 to my tblJOb table on a button click event. When I save the record using a VBA sql query, I want it to return The JobID (auto generated key) that was given to the newly created record. How can I do this? These are my table fields:
tblJob has the following fields:
JobID (Primary key - auto generated)
JobName
COntactName
ContactPhone
ContactEmail
thank you very much in advance,
mrotor
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Are you using bound forms? If you are, then there's no need to use DAO to save the data. Let Access do this instead.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Scott,
I am using an unbound table.
I will try Thommy's links and Helen's code a try.
mrotor
I am using an unbound table.
I will try Thommy's links and Helen's code a try.
mrotor