Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Time Elapsed
Message
From
06/06/2002 08:23:16
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Miscellaneous
Thread ID:
00665357
Message ID:
00665360
Views:
13
>Does FoxPro have a function that converts seconds
>to hour:minute:second?
>
>I am trying to calculate the time FoxPro takes to
>perform an action. I tried doing it this way:
>
> starttime=seconds()
>
> * carry out the action
>
> timetaken=seconds() - starttime
>
>Should I write a function to convert 'timetaken' to
>hours/minutes/seconds?
>
>Ria

Yes, I think your only viable option is to write your own function.

Use / (division) and % (remainder). Also, use padl(number, 2, "0") to fill out with zeroes.

HTH, Hilmar.
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Previous
Reply
Map
View

Click here to load this message in the networking platform