Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Elapsed time calculation has a bug in it? What is wrong?
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00612404
Message ID:
00612425
Vues:
33
>No, I'm not. Your quote is. Check my message. :)
>
>>He-he-he. You're so wrong. You will get negative elapsed time by this code :))
>>You need to switch datetime and newdate.
>>
>>>You can simplify your calculations
	elapsed = hospital.newdate - Datetime()
>>>	hrs3 = Int(elapsed/3600)
>>>	mins3 = Int((elapsed - (hrs3*3600)/60)
>>>	elapsed2 = Transform( hrs3*100 + mins3, "@RL 99:99")
>>>
>>>>Here's is my calculation for elapsed time. I subtract current time from start time to get elapsed time and show it as HH:MM in a listbox.
>>>>
>< snip >

Right. It's Steve, who made this confusion :)
If it's not broken, fix it until it is.


My Blog
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform