Am I guessing correctly that you are talking of a situation where the PK
field is an autonumber, and the record is added through code? If that's
correct, then the PK autonumber is assigned as soon as you execute
rst.AddNew, so anytime after this and before you move to a new record you
can get the PK value by means of rst.Fields("PKFieldName"). You can do so
even before the rst.Update is executed, it doesn't make a difference. All
that's required is the PK field to be included in the recordset SQL string
(if not a whole table).
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.