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?
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?