Adding Times Past 24 Hours in an Access Report

B

Brian

I've created a pilot's logbook in Microsoft Access, but cannot figure
out how to add times once the sum is greater than 24 hours (it goes to
00:01 AM on the next day). Can anybody help me? The field I'm trying
to sum is called [PIC]. Instead of 00:01AM, I want it to display
24:01.

Thanks in advance for your time. I've been stuck with this problem
for quite a while.
Brian
 
B

Brian

Hi Allen,

Thanks for getting back to me. Unfortunately, this method doesn't
seem to fit the way I've built my database. I'm summing short times
across multiple records at the bottom of each report page, as opposed
to summing fields within the same record...does this make sense? I'm
probably not explaining myself very clearly.

Thanks again.
Brian

Use DateDiff() to get the time in minutes.
You can then format it as hours and minutes on the report.

Details in:
Calculating elapsed time
at:
http://allenbrowne.com/casu-13.html

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users -http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.


I've created a pilot's logbook in Microsoft Access, but cannot figure
out how to add times once the sum is greater than 24 hours (it goes to
00:01 AM on the next day). Can anybody help me? The field I'm trying
to sum is called [PIC]. Instead of 00:01AM, I want it to display
24:01.
Thanks in advance for your time. I've been stuck with this problem
for quite a while.
Brian
 
T

Tom Wickerath

Hi Brian,

One of these articles should be helpful to you when working with dates:

How to store, calculate, and compare Date/Time data in Microsoft Access
http://support.microsoft.com/?id=210276

How to Calculate Daily Hours Based on Clock In/Clock Out Times
http://support.microsoft.com/?id=237958

On time and how much has elapsed
http://office.microsoft.com/en-us/assistance/HA011102181033.aspx

Using dates and times in Access
http://office.microsoft.com/en-us/assistance/HA010546621033.aspx

Calculate Number of Working Days
http://www.mvps.org/access/datetime/date0006.htm

Doing WorkDay Math in VBA
http://www.mvps.org/access/datetime/date0012.htm


Tom Wickerath
Microsoft Access MVP
https://mvp.support.microsoft.com/profile/Tom
http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________
 
A

Allen Browne

Do the calculation in a query.

For example, if you have date/time fields named TakeOffDateTime and
LandingDateTime, type an expression like this into the query:
Minutes: DateDiff("n", [TakeOffDateTime], [LandingDateTime])

You can then sum the minutes, and display them on the report as shown
previously.

--
Allen Browne - Microsoft MVP. Perth, Western Australia

Reply to group, rather than allenbrowne at mvps dot org.

Brian said:
Hi Allen,

Thanks for getting back to me. Unfortunately, this method doesn't
seem to fit the way I've built my database. I'm summing short times
across multiple records at the bottom of each report page, as opposed
to summing fields within the same record...does this make sense? I'm
probably not explaining myself very clearly.

Thanks again.
Brian

Use DateDiff() to get the time in minutes.
You can then format it as hours and minutes on the report.

Details in:
Calculating elapsed time
at:
http://allenbrowne.com/casu-13.html


I've created a pilot's logbook in Microsoft Access, but cannot figure
out how to add times once the sum is greater than 24 hours (it goes to
00:01 AM on the next day). Can anybody help me? The field I'm trying
to sum is called [PIC]. Instead of 00:01AM, I want it to display
24:01.
Thanks in advance for your time. I've been stuck with this problem
for quite a while.
Brian
 

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