I have asked this before but can't get the right answer. I am unsure if I have the bracketing right below for the line
rs.[Fivecents] = Me![Txtmultiply5cents]
[Fivecents] being the table field and [Txtmultiply5cents] being the unbound text box on the form.
Code:
Dim db As DAO.Database
Dim rs As DAO.Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset("TBLCashdeclaration", dbOpenDynaset)
rs.AddNew
rs.[Fivecents] = Me![Txtmultiply5cents]
rs!dtCreated = Now()
rs.Update
rs.Close
db.Close
Set rs = Nothing
Set db = Nothing
Can Anybody correct my error?
Thanks
rs.[Fivecents] = Me![Txtmultiply5cents]
[Fivecents] being the table field and [Txtmultiply5cents] being the unbound text box on the form.
Code:
Dim db As DAO.Database
Dim rs As DAO.Recordset
Set db = CurrentDb
Set rs = db.OpenRecordset("TBLCashdeclaration", dbOpenDynaset)
rs.AddNew
rs.[Fivecents] = Me![Txtmultiply5cents]
rs!dtCreated = Now()
rs.Update
rs.Close
db.Close
Set rs = Nothing
Set db = Nothing
Can Anybody correct my error?
Thanks