Calculating Average in Hours

G

G

Hi
I was hoping you all could help me in this sticky situation!! I've
tried searching all the groups but could'nt find something that would
work.
There is this widget factory, with the standard time it takes to make
one widget. I put in the data about how many widgets a worker has made
over his shift - lets say he's made 50 widgets in 8 hours and it takes
8 minutes to make one widget, so the average time he's taken to make
one widget is - (8 * 60) minutes = 480 / 50 = 9.6 mins per widget. If
one widget has a standard time of 8 minutes, he's done +1.6 mins over
the average.
The trouble I'm having is in calculating how many hours has he gone
over or below. Like, (1.6 min * 50 widgets) = 80 mins over or 1:20. I
can't get around converting 80 mins to hours in Access.
I've tried all sorts of stuff like Format( CDate([AvgMin] * [Parts]),
"Short Time"), but all it does is give me 00:00.
Would be grateful if anybody has any suggestions!!
Thanks!!
Jason
 
J

JK

Time in Access calculated on the basis that 1=1day

1.6*50/1440=0.055555 days

Format the field to ShortTime and you will get 1:20
This will work up to a maximum of 23:59, if you need more format to d:hh:nn

Regards/JK
 
G

G

Thanks a ton JK & chickenlittle! The code works like a charm, it's
solved a big headache for me

Regards
G
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top