Hi, Im trying to retrieve an autonumber generated by the insert query. I then select it into a recordset, taht goes ok but I get an error massage:
runtime error 424 object required
at the first line of the if statement, any help appreciated.
DoCmd.RunSQL "INSERT INTO clientservices2 ( serviceid, orgid) VALUES ( " & serviceid & ", " & orgid & ")"
DoCmd.RunSQL "SELECT Max(clientservices2.clientid) into rst from clientservices2"
If (rst.RecordCount > 0) Then
clientid2 = rst(0)
MsgBox "no record in rst"