Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to remove seconds in TIME() & subtract it.........
Message
From
11/08/2004 05:59:28
 
 
To
11/08/2004 05:34:23
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00930059
Message ID:
00932271
Views:
32

i mean

thisform.text1.value=04:45:00
thisform.text2.value=11:30:00 +
thisform.text3.value=08:25:00
----------
thisform.text4.value=24:40:00


run this:
clear
timeSum=		CTOT('04:45:00')-CTOT('0:')
timeSum=m.timeSum+(	CTOT('11:30:00')-CTOT('0:'))
timeSum=m.timeSum+(	CTOT('08:25:00')-CTOT('0:'))

? STUFF(TTOC(CTOT('0:')+m.timeSum,2),1,2,;
     STR(INT(VAL(TTOC(CTOT('0:')+m.timeSum,2)))+24*INT(m.timeSum/86400)))
then:
PRIVATE timeSum
timeSum=		CTOT(thisform.text1.value)-CTOT('0:')
timeSum=m.timeSum+(	CTOT(thisform.text2.value)-CTOT('0:'))
timeSum=m.timeSum+(	CTOT(thisform.text3.value)-CTOT('0:'))

thisform.text4.value= STUFF(TTOC(CTOT('0:')+m.timeSum,2),1,2,;
    STR(INT(VAL(TTOC(CTOT('0:')+m.timeSum,2)))+24*INT(m.timeSum/86400)))
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform