Try this:
nDuration = 7200
nDays = 0
nHours = 0
nMinutes = 0
= HowLong(nDuration, @nDays, @nHours,@nMinutes)
?nDays
?nHours
?nMinutes
nDuration = 420
nDays = 0
nHours = 0
nMinutes = 0
= HowLong(nDuration, @nDays, @nHours,@nMinutes)
?nDays
?nHours
?nMinutes
FUNCTION HowLong
LPARAMETER nDuration, nDays, nHours, nMinutes
** NOTE: The last three parms are passed by reference
LOCAL nDay
* How long is a day
nDay = 24 * 60
* Number of days
nDays = INT(nDuration/nDay)
* Remove the days
nDuration = nDuration - (nDays * nDay)
* How many hours
nHours = INT(nDuration/60)
* Remove the hours
nMinutes = nDuration - (nHours * 60)
>Does anybody have a routine written (that they will share) that will take an integer that represents minutes and turn it into a text format for hours/days
>
>Example: 7200 would return 5 Days
> 420 would return 7 Hours
>
>Thanks in advance.
>
>Kirk