I am trying to work out a difference between two time from a form.
I have a form the people put the Start Time and End Time Then in my VBA l have the following code.
Dim Lvalue As Integer
StartTime = [Forms]![Time]![Start]
EndTime = [Forms]![Time]![End]
Lvalue = DateDiff("n", StartTime, EndTime) / 60
but the Result comes out at 8 hrs if people put 9AM to 3:30PM round up to the nearest hour
Anyone got any suggestion why this is happening.
I have a form the people put the Start Time and End Time Then in my VBA l have the following code.
Dim Lvalue As Integer
StartTime = [Forms]![Time]![Start]
EndTime = [Forms]![Time]![End]
Lvalue = DateDiff("n", StartTime, EndTime) / 60
but the Result comes out at 8 hrs if people put 9AM to 3:30PM round up to the nearest hour
Anyone got any suggestion why this is happening.
Last edited: