how to add hours

If stored as hours /minutes in a text format, you could use:

Code:
Function ConvertToMins(strTimeString) As Long
Dim varSplit As Variant
Dim lngMins As Long
 
   VarSplit = Split(strTimeString, ":")
        lngMins = VarSplit(0) * 60
        lngMins = lngMins + VarSplit(1)
 
ConvertToMins = lngMins
 
End Function


And then you can Sum the minutes and then use the other to display the value in hours and minutes.
 
so where do i add this? as a function on the report?

this is how the daily hrs is computed:
Daily Hrs: CalcHrsOneDay([tblSchedule]![StartHr],[tblSchedule]![EndHr])

so where would i put the code you want? do i need to change anything to it?
 
What is your code for your CalcHrsOneDay function?
 
This thread is goingb round in circles
BTW 2.7916666666667 is about 67 hours

Do the Maths
2 = 2 days = 48 hours
.8*24 =19.2 hours

cant dp .79 in my head ;)

Brian
 

Users who are viewing this thread

Back
Top Bottom