Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
dim myDecimal, tempMinutes as double
dim hours, minutes as integer
myDecimal = 12.25
hours = cInt(myDecimal)
tempMinutes = (myDecimal - hours) * 100
minutes = cInt(tempMinutes)
Public Function basDbl2HrsMin(AccumTime As Double) As String
Dim tmpDays As Double
Dim tmpHrs As Double
Dim tmpMins As Double
Dim tmpTime As Double
Dim tmpStr As String
tmpDays = Int(AccumTime)
tmpTime = (AccumTime - tmpDays) * 1440 'Fraction to Mins
tmpMins = tmpTime Mod 60
tmpTime = tmpTime - Int(tmpMins)
tmpHrs = tmpTime \ 60
'formatting for Day(s)
If (tmpDays) Then
tmpStr = tmpDays & "Day"
If (tmpDays > 1) Then
tmpStr = tmpStr & "s"
End If
End If
'formatting for Hour(s)
If (tmpHrs) Then
tmpStr = tmpStr & " " & tmpHrs & "Hr"
If (tmpHrs > 1) Then
tmpStr = tmpStr & "s"
End If
End If
'formatting for Minutes(s)
If (tmpMins) Then
tmpStr = tmpStr & " " & tmpMins & "Min"
If (tmpMins > 1) Then
tmpStr = tmpStr & "s"
End If
End If
basDbl2HrsMin = tmpStr
End Function