Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Does focus.fll do this?
Message
De
01/07/1998 20:35:29
 
 
À
01/07/1998 08:38:15
Information générale
Forum:
Visual FoxPro
Catégorie:
Produits tierce partie
Divers
Thread ID:
00113207
Message ID:
00113621
Vues:
18
>>Pat,
>> Does focus.fll have an internal function that converts seconds to the hh:mm:ss format? For example, 110 seconds would convert to 00:01:50.
>
>>
>>TIA,
>
>Yes it does. The function is called TIM_FormatMilli().
>In fact you pass it a number of milliseconds and it will return you a string which is formatted a slightly different way : hh:mm:ss.ttt where ttt stands for thousands of a second.
>
>So to get back to your example you need to apply the following code :
>
>? LEFT( TIM_FormatMilli( 110 * 1000 ),8 )
>
>There is also another function : TIM_SplitMilli() that splits a number of milli seconds into hours, minutes, seconds, and thousands of a second :
>
>h = 0
>m = 0
>s = 0
>t = 0
>
>? TIM_SplitMilli( 110 * 1000,@h,@m,@s,@t )
>
>? h && 0
>? m && 1
>? s && 50
>? t && 0
>
>
>Hope this helps.
>
>Pat

I am using your function as shown above in a report. It is MUCH faster than anything I have tried to this point. Additionally, if you need to use it to average a column in the page footer you can use:

? LEFT( TIM_FormatMilli( INT(ROUND(110.50,0)) * 1000 ),8 )

Perhaps you can add a function that just does HH:MM:SS to focus?

Thanks for your help,
William Chadbourne
Senior Programmer/Analyst
State of Maine - DAFS App Team

Oracle - When you care enough to use the very best!!
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform