lord nikon007
Baseband Member
- Messages
- 21
I want this append query to run everytime the return button is pressed but i keep getting an error saying this is an invalid action. the query runs fine. the heck is wrong?
Private Sub cmdReturn_Click()
Dim dbs As Database
Dim rstApp As DAO.Recordset
'***** This runs the Append query to add the new records
'***** to the projects list before returning to the switchboard.
Set dbs = CurrentDb
Set rstApp = dbs.OpenRecordset("qryAppend", dbOpenDynaset)
'***** This closes the form without submitting
'***** the records to the table.
rstApp.Close
dbs.Close
DoCmd.Close
End Sub
Private Sub cmdReturn_Click()
Dim dbs As Database
Dim rstApp As DAO.Recordset
'***** This runs the Append query to add the new records
'***** to the projects list before returning to the switchboard.
Set dbs = CurrentDb
Set rstApp = dbs.OpenRecordset("qryAppend", dbOpenDynaset)
'***** This closes the form without submitting
'***** the records to the table.
rstApp.Close
dbs.Close
DoCmd.Close
End Sub