Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Sum time field
Message
From
07/01/2005 08:14:34
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Environment versions
Visual FoxPro:
VFP 5
Database:
Visual FoxPro
Miscellaneous
Thread ID:
00974644
Message ID:
00975035
Views:
21
hi,
thank you so much,it works,
i need a faver, i want to multiplay the result time with 11.9$ as
01:30*11.9=17.85

i'll try but i get result just for hour as..11.9
THISFORM.TEXT1.VALUE= PADL(INT(lnSec/3600), 2, "0") + ":" + ;
			PADL(INT((lnSec%3600)/60),2, "0")  
			*PADL(lnSec % 60,2, "0")

			THISFORM.TEXT2.VALUE=VAL(THISFORM.TEXT1.VALUE)*11.9
thanks.
m.qasem

>The oldest version I've is VFP8 and I get correct result under it. Here's my test code( 2 vesrsions)
CREATE CURSOR test (tim c(8))
>INSERT INTO test VALUES("10:30:15")
>INSERT INTO test VALUES("12:30:15")
>INSERT INTO test VALUES("18:00:10")
>INSERT INTO test VALUES("10:10:30")
>
>SUM CTOT(tim) - CTOT("00:00:00") to lnSec
>? PADL(INT(lnSec/3600), 2, "0") + ":" + ;
>				PADL(INT((lnSec%3600)/60),2, "0") + ":" + ;
>				PADL(lnSec % 60,2, "0")
>
>SUM VAL(LEFT(tim,2))*3600 + ;
>	VAL(SUBSTR(tim,4,2))*60 + ;
>	VAL(RIGHT(tim,2)) TO lnSec
>
>? PADL(INT(lnSec/3600), 2, "0") + ":" + ;
>				PADL(INT((lnSec%3600)/60),2, "0") + ":" + ;
>				PADL(lnSec % 60,2, "0")
>
>
>>thank you for reply,
>>i try as under,but i get error result .the result is 15
>>but the data at myfield as under
>>rec1. tim= 10:30:15
>>rec2 = 12:30:15
>>rec3 = 18:00:10
>>rec4 = 10:10:30
>>
>>i need the result as 51:11:10
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform