Unanswered: Running sum hours returns incorrect sums
I have a table with an hoursworked field in short time format , however when I try to use running some on the hoursworked field I get incorrect sums when the hours exceed 24hrs . Does any body have a workaround for this ?
if all you are doing is summng hours such as totalnumber of hours - try using a number format - I would have to see the data to give a better idea but a total number of hours is not time it is a number.
Let me know if this helps or if you want me to look at an example.
When I swithch the text box ( and the table field ) to a general number it calculates to 0.00 . To explain it better , I have a Clockin field and a Clockout field and an hoursworked field . Clockin and Clockout are populated by "setvalue Now()" via a button . hoursworked is populated by "setvalue Clockout - Clockin " so all fields are populated by date formats and everything is correct except when i try to do a sum in a report
not working , I either get a zero returned or I get 0.30934234222354 when I should be getting 6:34 hrs ? I'm doing this directly in the table and getting these results . When I set all three fields to short date , the hours worked is correct , the problem comes when i go to create a total in a report . I assign the text box to hoursworked and then set it to running sum , I change the format to number and the results are crazy .
The report in question is lat7days , I know the data is not correct for the hoursworked compared to the clockin / clockout times , this was due to me changing formats and blowing out the old data . it still gives me the same results on the report though .
I took a look at it and I see you are multiplying the hoursworked number by 24 after subtracting clockin from clockout but what is Csng ? and when would I run this query ? Should I run it every time someone clocks out ? BTW Thanks a ton ! It does function well now !