Hi Guys,
I've been looking for a bit on information about INSERT statements and I really haven't found much. So I find myself here again!
All I want to do is a basic INSERT Statement where the user will input data into text boxes, then when the save button is clicked, the code will insert this into the table
Here's the code I have - but it's complaining about too few parameters which maybe might be to do with how I've inserted the text boxes into the statement I don't know
As always, any help is always appreciated! Thanks,
Ryan
I've been looking for a bit on information about INSERT statements and I really haven't found much. So I find myself here again!
All I want to do is a basic INSERT Statement where the user will input data into text boxes, then when the save button is clicked, the code will insert this into the table
Here's the code I have - but it's complaining about too few parameters which maybe might be to do with how I've inserted the text boxes into the statement I don't know
Code:
Private Sub btnSave_Click()
SQLReg = "INSERT INTO tblAircraftDetails (Registration, Model, SeatsAvailable, Remarks) " & _
" VALUES(txtRegistration, txtModel, txtSeats, txtRemarks)"
CurrentDb.Execute (SQLReg)
End Sub
As always, any help is always appreciated! Thanks,
Ryan