Hi
I am trying to append data from a form to a table. I have completed the vba below with out success. Can anyone help!
Dim intBatchNumber As Integer
Dim strType As String
Dim dbs As Database
Set dbs = OpenDatabase("PrintActivity.mdb")
intBatchNumber = Forms![New_frmPrintActivityAmend]![PrintBatchNumber]
strType = Forms![New_frmPrintActivityAmend]![Type]
dbs.Execute "INSERT INTO tblDeletedBatches (PrintBatchNumber, Type) VALUES ('intBatchNumber', 'strType');"
dbs.Close
End Sub
Thanks in advance..........
I am trying to append data from a form to a table. I have completed the vba below with out success. Can anyone help!
Dim intBatchNumber As Integer
Dim strType As String
Dim dbs As Database
Set dbs = OpenDatabase("PrintActivity.mdb")
intBatchNumber = Forms![New_frmPrintActivityAmend]![PrintBatchNumber]
strType = Forms![New_frmPrintActivityAmend]![Type]
dbs.Execute "INSERT INTO tblDeletedBatches (PrintBatchNumber, Type) VALUES ('intBatchNumber', 'strType');"
dbs.Close
End Sub
Thanks in advance..........