Sub Submit ()
Dim d, rs As Object
Dim mySQL As String
Set d = CreateObject("accesss.application") <----having trouble here!
d.opencurrentdatabase ("path here")
d.DOCMD.SetWarnings False
mySQL = "insert into working_hours (effective_date, fac, bldg, start_of_day, end_of_day) values (" & EffDate & ", " & fac & _
", " & bldg & ", " & SoD & ", " & EoD & ");"
Set rs = d.Execute(mySQL)
End Sub
I have a button 'update assigned to this macro where i am bringing values in and pasting them into an access database.
Bookmarks