Syntax error (missing operator) in query expression

rikklaney1

Registered User.
Local time
Yesterday, 20:15
Joined
Nov 20, 2014
Messages
157
So I'm getting an error telling me

Run time error '3075'
Syntax error (missing operator) in query expression '8/24/2015 2:10:39 PM'

When I have this as an on click event for a button.

DoCmd.RunSQL "UPDATE [tblexelpick] SET [close time] = " & Now() & " WHERE [tblexelpick].[ID] = " & Me.List26.Column(0, 0)



When I click the button I need it to put the current time in the [close time] field of the first record in list26. Any ideas what I'm doing wrong?
 
Try

DoCmd.RunSQL "UPDATE [tblexelpick] SET [close time] = #" & Now() & "# WHERE [tblexelpick].[ID] = " & Me.List26.Column(0, 0)
 
That did it. Thanks for the help. Much appreciated
 

Users who are viewing this thread

Back
Top Bottom