Hi there. Trying to add a new record, while filling some of the fields in with information from the current record in another table:
Creates the new record with agencyid equalling 1, but can't get the other part to work? Any ideas?
Thanks for readin'
-Shurgs
Code:
Set db = CurrentDb
Set rs = db.OpenRecordset("referral")
rs.AddNew
rs("agencyid") = 1
rs("progid") = db.Execute("SELECT pid FROM progress WHERE pid = IDENT_CURRENT('progress')")
rs.Update
rs.Close
Thanks for readin'
-Shurgs