Help with time tracking database

G

Guest

lol, Sorry about that, I did replace the generic names with the ones I'm
using, I just plasted the code from your earlier post on that last post.
With the right names, it is giving me that error.

Do you have
 
G

Guest

I will be working on this all night, so if you can stay on and help me out
that will be great. I really need to get this to work so I will be very
appreciative if you can stay on and help me out.

Thanks
 
K

Ken Snell \(MVP\)

What type of data field is EmpID field? If it's text, you need to delimit
the value with ' characters:

varTimeDate = DMax("TimeStampField", "TableName", "EmpID= '" & _
Me.EmpID.Value & "' And TimeStampField<#" & _
Format(Me.TimeStampField.Value, "m\/d\/yyyy h\:nn\:ss") & "#")
 
G

Guest

ya it is a text data type, what do I need to change in this code then :
varValue = DLookup("ClockIn", "TimeClock", "TimeStamp=#" & _
Format(datTimeDate, "m\/d\/yyyy h\:nn\:ss") & "# And SSN= " & _
Me.SSN.Value)
 
K

Ken Snell \(MVP\)

varValue = DLookup("ClockIn", "TimeClock", "TimeStamp=#" & _
Format(datTimeDate, "m\/d\/yyyy h\:nn\:ss") & "# And SSN= '" & _
Me.SSN.Value & "'")
--

Ken Snell
<MS ACCESS MVP>

Chou said:
ya it is a text data type, what do I need to change in this code then :
varValue = DLookup("ClockIn", "TimeClock", "TimeStamp=#" & _
Format(datTimeDate, "m\/d\/yyyy h\:nn\:ss") & "# And SSN= " & _
Me.SSN.Value)


< snipped >
 
G

Guest

Hi Ken,

How do you get the toggle button to pop back out. You told me to set it to
null, I've tried a few things but I can not get it right. Can you show me
how to do it.

So far I have put this command into the on click event so that the record
will submit.

DoCmd.GoToRecord , , acNewRec
 
K

Ken Snell \(MVP\)

As I noted earlier, you need to set the value of the option group control to
Null. The option group control is the control that houses the two toggle
buttons.

Here is some simple code:

Me.NameOfOptionGroupControl.Value = Null


Note that the default name for an option group control that ACCESS assigns
begins with Frame.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Daily Time Sheets with Rounding 1
Time clock 2
Time Clock 6
calculate time to complete application 8
How to calulate time 3
Convert Time 10
Append data from one database to another 1
Add Time Q 4

Top