PDA

View Full Version : total time subtract 30



talytech
01-06-2012, 11:41 AM
I've posted this on another forum but haven't got that far but what I'm having a problem with is calculating time between 2 times and subtracting 30 minutes. The link below is the post that I posted to the other forum. I'm in desperate need of some answers. Can someone assist me with this issue.

http://www.access-programmers.co.uk/forums/showthread.php?t=220329

jrajul
01-07-2012, 06:52 PM
Dim DateNTimeOut as date
'Should be the entire date and time: "01/07/12 7:45 AM" and not just "7:45 AM".



Dim DateNTimeIn as date

Dim Time ExpressedInDays as date
Dim Running Total as single


For counter=Sunday to Saturday

'I would need to know how you store the _
'times to tell you what kind of loop to use.



TimeExpressedInDays=DateNTimeOut-DateNTimeIn - ((1/1440)*30)
TimeInMinutes=TimeExpressedInDays*1440

RunningTotal=RunningTotal+TimeInMinutes



next counter

Debug.print RunningTotal