O
open a adobe file from a command button
I'm using the following code to update 2 fields in a table:
Private Sub Form_Unload(Cancel As Integer)
Dim strSQL As String
strSQL = "update [tbl-offsites]" _
& "set releasedDate = #" & Date & "#" _
& "where [Vault No] = " _
& Nz(Me![Vault No]) & ";"
Debug.Print strSQL
CurrentDb.Execute strSQL, dbFailOnError
End Sub
It works, but when I add the following "& storagelocation = '27' _" after
"[Vault No]it errors on the CurrentDb.Execute and I don't understand. Could
someone please tell me what I'm doing wrong
Private Sub Form_Unload(Cancel As Integer)
Dim strSQL As String
strSQL = "update [tbl-offsites]" _
& "set releasedDate = #" & Date & "#" _
& "where [Vault No] = " _
& Nz(Me![Vault No]) & ";"
Debug.Print strSQL
CurrentDb.Execute strSQL, dbFailOnError
End Sub
It works, but when I add the following "& storagelocation = '27' _" after
"[Vault No]it errors on the CurrentDb.Execute and I don't understand. Could
someone please tell me what I'm doing wrong