Can you just get Time Value of date time stamp?

cliff7376

Registered User.
Local time
Today, 19:52
Joined
Oct 10, 2001
Messages
107
I have a job wanding system that involves people logging start times and stop times of jobs in the system. The problem i am having is that the system works off a date/time system. I need to make an adjustment to the code to account for lunch. so i made this if statement

If Me.txtLabStartDate.value < "12:30:00 PM" And Me.txtLabStopDate.value > "1:00:00 PM" Then
Me.txtLabHours = Round(DateDiff("S", varLabStartDate, varLabStopDate) / 3600, 4)-.5
Call EnableFields(LOWER_SECTION, True)
Call EnableFields(ACCEPT_UNDO, True)
End If

the problem i am having is that txtLabStartDate and txtLabStopDate are formated as date time. i tried to change that and broke some code. so I need to know how to just get the time out of the text box.

can anyone help me?
 
Not sure if I understand the question, but can´t you use the timevalue function for this sort of thing?

:confused:
Fuga.
 
yes that is exactly what i was looking for. I new you could get just the date with the dateval() i didn't know the time one. thank you very much.:)
 

Users who are viewing this thread

Back
Top Bottom