S
Steven Scaife
I need to subtract 2 values and then stick the value in a table that isnt
linked to the form. i have tried
[Book]![In_Stock] = [Book]![In_Stock] - [txtQuantityBook]
but have realised that it wont work because it doesnt give a row. So i
tried creating a recordset and use SQL instead but i get an error 2467 the
expression refers to an object that doesnt exist or is closed, using this
code
Dim rst As Recordset
Dim strSQL As String
strSQL = "UPDATE Book SET In_Stock ='" & txtQuantityBook & "' WHERE
Book_Title = '" & Combo12 & "'"
rst.Update 'i know i shouldnt use the default name that access gives me
but i forgot to change it.
what is it that i am missing?
thanks in advance for any help
linked to the form. i have tried
[Book]![In_Stock] = [Book]![In_Stock] - [txtQuantityBook]
but have realised that it wont work because it doesnt give a row. So i
tried creating a recordset and use SQL instead but i get an error 2467 the
expression refers to an object that doesnt exist or is closed, using this
code
Dim rst As Recordset
Dim strSQL As String
strSQL = "UPDATE Book SET In_Stock ='" & txtQuantityBook & "' WHERE
Book_Title = '" & Combo12 & "'"
rst.Update 'i know i shouldnt use the default name that access gives me
but i forgot to change it.
what is it that i am missing?
thanks in advance for any help